RE: d2i_RSAPublicKey doesn't work

2005-07-21 Thread Edward Chan
Horray...that is it. Thanks!!! > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Edward Chan > Sent: Thursday, July 21, 2005 11:00 AM > To: openssl-users@openssl.org > Subject: RE: d2i_RSAPublicKey doesn't work > > So I need to save buf to a tmp fi

Re: d2i_RSAPublicKey doesn't work

2005-07-21 Thread Dr. Stephen Henson
On Thu, Jul 21, 2005, Edward Chan wrote: > So I need to save buf to a tmp first like with d2i_RSAPublicKey? > > Like this: > > int len = i2d_RSAPublicKey(rsa, 0); > unsigned char* buf = new unsigned char[len]; > unsigned char* tmp = buf; > i2d_RSAPublicKey(rsa, &tmp); > > // now use buf to dec

RE: d2i_RSAPublicKey doesn't work

2005-07-21 Thread Edward Chan
So I need to save buf to a tmp first like with d2i_RSAPublicKey? Like this: int len = i2d_RSAPublicKey(rsa, 0); unsigned char* buf = new unsigned char[len]; unsigned char* tmp = buf; i2d_RSAPublicKey(rsa, &tmp); // now use buf to decode Is this correct? > -Original Message- > From: [E

Signing a CSR with Microsoft CA

2005-07-21 Thread Dave Morrow
Title: Signing a CSR with Microsoft CA Hi all, I am attempting to sign an OpenSSL generated CSR with Microsoft Certification Authority.  I generated the CSR using the instructions the instructions on the Apache website and successfully got the CSR.  When I attempt to sign the CSR using Mic

Re: d2i_RSAPublicKey doesn't work

2005-07-21 Thread Dr. Stephen Henson
On Thu, Jul 21, 2005, Edward Chan wrote: > The code is basically like this: > > int len = i2d_RSAPublicKey(rsa, 0); > > // allocate buffer > unsigned char* buf = new unsigned char[len]; > > // now call again to DER encode the public key > if (i2d_RSAPublicKey(rsa,

RE: d2i_RSAPublicKey doesn't work

2005-07-21 Thread Edward Chan
The code is basically like this: RSA* rsa = RSA_generate_key(2048, RSA_F4, 0, 0); // check if RSA key is valid if (rsa && RSA_check_key(rsa) > 0) { // find size of buffere required to encode public key int len = i2d_RSAPublicKey(rsa, 0); // allocate buffer unsigned

Re: Verify Certificate

2005-07-21 Thread francesco
Thanks! it works2005/7/21, Jorey Bump <[EMAIL PROTECTED]>: francesco wrote:> I found some problems to verify the certificate I created with my own CA.> I don't know which certificates have to be included in the -CApath option.> I created a self signed cert and a server cert, then I created a > clie

Re: Verify Certificate

2005-07-21 Thread Jorey Bump
francesco wrote: I found some problems to verify the certificate I created with my own CA. I don't know which certificates have to be included in the -CApath option. I created a self signed cert and a server cert, then I created a client cert (using ever the same key) and I tried to verify it wit

Re: [dev-crypto] Re: Use PolicyInformation class

2005-07-21 Thread pana
That's true! When the program executes this line: asn1Input = new ASN1InputStream(policyInformationOctetString.getOctets()); Checking the dedug mode, the variables assume this value: asn1Input= ASN1InputStream  (id=74)     END_OF_STREAM= ASN1InputStream$1  (id=75)     eofFound= false     in= Byte

Verify Certificate

2005-07-21 Thread francesco
I found some problems to verify the certificate I created with my own CA. I don't know which certificates have to be included in the -CApath option. I created a self signed cert and a server cert, then I created a client cert (using ever the same key) and I tried to verify it with the command "open

Special Microsoft Attributes

2005-07-21 Thread Stephan Uhde
Hello, We have successfully tested active-directory-logon with x509v3 certificates at a windows server 2003 domain based on certificates which have been generated with the cryptolibrary OpenSSL-0.9.8. In order to verify client certificates, the test certificate-chain, consisting of a root-CA

Linking errors while compilation. Please Help

2005-07-21 Thread Sitaram
Hi   I am facing a problem in compiling the openssl -0.9.7g version. I am using PERL to compile this. The following are the steps I am following in the compilation:   1)  Type “perl Configure no-idea no-mdc2 no-rc5 no-rc2 no-rc4 VC-WIN32” 2)  Type “ms\do_nasm” 3)  Type "nmake -f ms\ntd

Re: d2i_RSAPublicKey doesn't work

2005-07-21 Thread Dr. Stephen Henson
On Wed, Jul 20, 2005, Edward Chan wrote: > Hmm, well, I guess I assumed i2d_RSAPublicKey() was ok since the RSA key > seems fine (I ran RSA_check_key() on it and it says it is ok). Is there > any reason why i2d_RSAPublicKey() would not be returning me valid data? > Normally only if it is not ca

Re: Machine certificate

2005-07-21 Thread Babak Nasri
No actually notthing more than the opnessl.cnf and the usual way you take to generate the cert-req (and resp. the certificate) should be needed. after using something like the attached config file you can take this steps(or an altenative that makes the most sense for you): openssl genrsa -des3

Re: [dev-crypto] Re: Use PolicyInformation class

2005-07-21 Thread pana
I tried also with ASN1Sequence. The exact problem is that when the program is going to execute PolicyInformation.getInstance(), it launches an exception and terminates. Can you help me? bye pana 2005/7/18, David Hook <[EMAIL PROTECTED]>: > > Can you tell me more about the exact problem you are