osdir.com
mailing list archive F.A.Q. -since 2001!



Subject: PKCS8 decrypt Privatekey - msg#00019

List: encryption.bouncy-castle.devel

Mail Archive Navigation:
by Date: Prev Next Date Index by Thread: Prev Next Thread Index

Hi all,

 

Hope you can help; I have searched for hours and tried various ways to solve this.

I have a private key which is retrieved from an ldap store in the form of a byte[] which is PKCS8 encoded with a password.

 

My question is how do I retrieve the Private Key and decrypt it using Bouncy castles PEMReader, I might be going about this the wrong way but when I read the Object it always comes back null.

 

 

Thanks

 

 

******************************************** 
Larry Edwardson 
CITEC Software Services
192 Ann Street, Brisbane, QLD, 4000
Telephone: (+61 7) 3006 4733 
Larry.Edwardson-Y6moF6ZLOIH0CCvOHzKKcA@xxxxxxxxxxxxxxxx
 
CITEC, a national information and communications technology (ICT) service provider, manages two high security data centres located in Brisbane and Sydney and provides Information Brokerage; Business Process Outsourcing and Applications Management; Infrastructure Management and ICT Professional Services.

********************************************

 

  This email and associated attachments may contain confidential and privileged CITEC information that is provided solely for the use of the intended addressee. Views and opinions expressed in this email are those of the individual sender and are not necessarily the views and opinions of CITEC unless the sender expressly states that such views and opinions are those of CITEC. The privilege and confidentiality associated with this email and attachments will not be waived, lost or rescinded by reason of mistaken delivery. Should you receive this email by mistake, please notify the sender by return email then delete the email from your computer system. You must not use, copy, modify, print, or distribute the email or the information and attachments contained within same to any third party. CITEC does not accept any liability in respect of viruses or computer problems experienced by the recipient through access gained to this email and its attachments.

________________________________________________________________________
This email has been scanned for viruses by the CITEC Email Anti-Virus service powered by MessageLabs. For more information on a proactive email anti-virus service working around the clock, around the globe, visit www.citec.com.au
________________________________________________________________________

Thread at a glance:

Previous Message by Date:

Re: hash function

Jung, Eric wrote: > I thought someone might know the > answer and could save me a few days of reading SHA specifications Here's a very good summary of the various SHA family of functions and their differences: http://home.ecn.ab.ca/~jsavard/crypto/mi060501.htm Some quotes from that: "The SHA-256 algorithm is very similar in structure to SHA-1, but not only does it use eight, rather than five, 32-bit subblocks, but there are other ways in which it is not analogous. For SHA-256, the message is padded, and divided into 512-bit blocks, in the same way as for SHA-1." [ ... ] "Thus, one important difference between SHA-256 and SHA-1 is that the nonlinear functions do not change during the hashing of a block, but instead of having only four constants, each of which is used for 20 words, there are now 64 constants, each used for only one word." The cited page will give you the details without the effort of deciphering the individual specifications. -- sidney markowitz http://www.sidney.com

Next Message by Date:

PKCS#7 from X509Cert

I have a PKCS12 keystore from which I would like to extarct the the X509 Cert and then store the cert in a PKCS#7 format. Can anyone point me to some code examples of building a PKCS#7 object from an X.509 Cert . I am presuming that this is done using the BC CMS libs. Thanks, Rod Madden

Previous Message by Thread:

hash function

Hi, Would appreciate any help on this question. I thought someone might know the answer and could save me a few days of reading SHA specifications. I know this isn't a bouncycastle-specific question, so please feel free to direct me to the correct mailing list. Is the only difference between SHA-1 and SHA-256 the size of the message digest? (160-bit vs. 256-bit) Thank you, Eric Jung

Next Message by Thread:

Re: PKCS8 decrypt Privatekey

There's something you might want to check. In most cases these are stored as EncryptedPrivateKeyInfo objects - there's direct support for dealing with these in the JCE. Are you sure the object has been encoded using the OpenSSL format - it's not the same as PKCS#8 Regards, David On Thu, 2005-05-05 at 16:58 +1000, Larry Edwardson wrote: > Hi all, > > > > Hope you can help; I have searched for hours and tried various ways to > solve this. > > I have a private key which is retrieved from an ldap store in the form > of a byte[] which is PKCS8 encoded with a password. > > > > My question is how do I retrieve the Private Key and decrypt it using > Bouncy castles PEMReader, I might be going about this the wrong way > but when I read the Object it always comes back null. > > > > > > Thanks > > > > > > ******************************************** > Larry Edwardson > CITEC Software Services > 192 Ann Street, Brisbane, QLD, 4000 > Telephone: (+61 7) 3006 4733 > Larry.Edwardson-Y6moF6ZLOIH0CCvOHzKKcA@xxxxxxxxxxxxxxxx > > CITEC, a national information and communications technology (ICT) > service provider, manages two high security data centres located in > Brisbane and Sydney and provides Information Brokerage; Business > Process Outsourcing and Applications Management; Infrastructure > Management and ICT Professional Services. > > ******************************************** > > > > > > > ______________________________________________________________________ > This email and associated attachments may contain confidential and > privileged CITEC information that is provided solely for the use of > the intended addressee. Views and opinions expressed in this email are > those of the individual sender and are not necessarily the views and > opinions of CITEC unless the sender expressly states that such views > and opinions are those of CITEC. The privilege and confidentiality > associated with this email and attachments will not be waived, lost or > rescinded by reason of mistaken delivery. Should you receive this > email by mistake, please notify the sender by return email then delete > the email from your computer system. You must not use, copy, modify, > print, or distribute the email or the information and attachments > contained within same to any third party. CITEC does not accept any > liability in respect of viruses or computer problems experienced by > the recipient through access gained to this email and its attachments. > > ______________________________________________________________________ > > ________________________________________________________________________ > This email has been scanned for viruses by the CITEC Email Anti-Virus > service powered by MessageLabs. For more information on a proactive > email anti-virus service working around the clock, around the globe, > visit www.citec.com.au > ________________________________________________________________________
blog comments powered by Disqus

Home | News | Sitemap | FAQ | advertise | OSDir is an Inevitable website. GBiz is too!