RE: private key not available for client_cert_cb

2021-01-12 Thread Michael Wojcik
> From: openssl-users On Behalf Of George > Sent: Tuesday, 12 January, 2021 00:18 > I'm running this in Windows 10 and when I load the smart card middleware > PKCS11 DLL, I see the exception: > Exception thrown at 0x773046D2 in GENCom.exe: Microsoft C++ exception: > unsigned long at memory locati

Re: private key not available for client_cert_cb

2021-01-11 Thread George
I'm running this in Windows 10 and when I load the smart card middleware PKCS11 DLL, I see the exception: Exception thrown at 0x773046D2 in GENCom.exe: Microsoft C++ exception: unsigned long at memory location 0x07FCFA00. During mutual authentication, I also see alot of other exceptions

Re: private key not available for client_cert_cb

2021-01-11 Thread George
I found out what my problem is! I'm running it in FIPS mode and this causes the PKCS11 engine to fail during mutual authentication. I eventually traced the problem to the following issue: https://bugzilla.redhat.com/show_bug.cgi?id=1827535 It looks like there is a bug in libp11. Once I made the

Re: private key not available for client_cert_cb

2021-01-11 Thread Jan Just Keijser
Hi, On 08/01/21 22:35, George wrote: Hi,    I have been trying to setup mutual authentication using a smart card but I can't seem to get the OpenSSL Engine to send a response back to the server containing client's certificate from the smart card. I'm using the following to configure the cer

RE: private key not available for client_cert_cb

2021-01-11 Thread Michael Wojcik
> From: openssl-users On Behalf Of George > Sent: Sunday, 10 January, 2021 21:01 > Right now I am using the "libp11" DLL (i.e. > libp11-libp11-0.4.11\src\pkcs11.dll) > with my PKCS11 smart card middleware DLL. Should I be using the OpenSC pkcs11 > DLL > instead of my middleware DLL if I am usin

Re: private key not available for client_cert_cb

2021-01-10 Thread George
Hi,     I had a look at the pkcs11-helper and can see where the RSA_METHOD_FLAG_NO_CHECK is being set. It's using a session object called pkcs11h_openssl_session_t, which I do not see in the libp11 or openSC code. Right now I am using the "libp11" DLL (i.e. libp11-libp11-0.4.11\src\pkcs11.d

RE: private key not available for client_cert_cb

2021-01-08 Thread Michael Wojcik
> From: openssl-users On Behalf Of George > Sent: Friday, 8 January, 2021 14:35 > The comment indicates that the flag RSA_METHOD_FLAG_NO_CHECK should be set > for smart cards[...] > However, it is not actually set when I use a debugger to inspect the flag. > Does it need to be set? If so, how is

Re: private key not available for client_cert_cb

2021-01-08 Thread George
Hi,    I have been trying to setup mutual authentication using a smart card but I can't seem to get the OpenSSL Engine to send a response back to the server containing client's certificate from the smart card. I'm using the following to configure the certificate and private key:     ENGINE_c

Re: private key not available for client_cert_cb

2021-01-05 Thread Jan Just Keijser
Hi, On 05/01/21 07:39, George wrote: Hi,     I was looking at the  code in https://github.com/jjkeijser/ppp/blob/eap-tls/pppd/eap-tls.c and realized I forgot to call ENGINE_ctrl_cmd(...) to setup "LOAD_CERT_CTRL". However, when I do this, the callback function is no longer being called duri

Re: private key not available for client_cert_cb

2021-01-04 Thread George
Hi,     I was looking at the  code in https://github.com/jjkeijser/ppp/blob/eap-tls/pppd/eap-tls.c and realized I forgot to call ENGINE_ctrl_cmd(...) to setup "LOAD_CERT_CTRL". However, when I do this, the callback function is no longer being called during the mutual authentication handshake.

Re: private key not available for client_cert_cb

2020-12-23 Thread Jan Just Keijser
Hi, On 20/12/20 09:39, George wrote: Hi,    I tried running the "s_client" command and it appears to be working. I guess there must be something wrong in my code. it is good news that the s_client command is working - it means there is something wrong with your code but you have everything

Re: private key not available for client_cert_cb

2020-12-20 Thread George
Hi,    I tried running the "s_client" command and it appears to be working. I guess there must be something wrong in my code. My crash occurs when I call ENGINE_init(pkey_engine); I notice your code does not call this function.  Is this needed needed? If so, when/where should it be called?

Re: private key not available for client_cert_cb

2020-12-19 Thread Jan Just Keijser
Hi, On 19/12/20 04:48, George wrote: Hi,   I narrowed the problem down to ENGINE_set_default(pkey_engine, ENGINE_METHOD_ALL) This causes the initial exception Exception thrown at 0x757346D2 in GENCom.exe: Microsoft C++ exception: unsigned long at memory location 0x006FCD68. It looks like so

Re: private key not available for client_cert_cb

2020-12-18 Thread George
Hi,   I narrowed the problem down to ENGINE_set_default(pkey_engine, ENGINE_METHOD_ALL) This causes the initial exception Exception thrown at 0x757346D2 in GENCom.exe: Microsoft C++ exception: unsigned long at memory location 0x006FCD68. It looks like some of the Engine methods cause an excep

Re: private key not available for client_cert_cb

2020-12-18 Thread Jan Just Keijser
Hi, On 18/12/20 06:21, George wrote: Hi,    I'm able to setup the engine now, but as soon as I attempt to execute the command ENGINE_set_default(pkey_engine, ENGINE_METHOD_ALL); ,I see all kinds of middleware exceptions being generated: Exception thrown at 0x773046D2 in GENCom.exe: Microsoft

Re: private key not available for client_cert_cb

2020-12-17 Thread George
Hi,    I'm able to setup the engine now, but as soon as I attempt to execute the command ENGINE_set_default(pkey_engine, ENGINE_METHOD_ALL); ,I see all kinds of middleware exceptions being generated: Exception thrown at 0x773046D2 in GENCom.exe: Microsoft C++ exception: unsigned long at memor

Re: private key not available for client_cert_cb

2020-12-17 Thread Jan Just Keijser
On 17/12/20 14:55, George wrote: Ok. So I use the libp11 project DLL file for the SO_PATH and my smart card middleware DLL for the MODULE_PATH when setting up the OpenSSL Engine? yes just like in the example I posted below. I would recommend the p11 wiki page to do it using the command line

Re: private key not available for client_cert_cb

2020-12-17 Thread George
Ok. So I use the libp11 project DLL file for the SO_PATH and my smart card middleware DLL for the MODULE_PATH when setting up the OpenSSL Engine? Thanks, George On 2020-12-17 3:22 a.m., Jan Just Keijser wrote: Hi, On 16/12/20 20:26, George wrote: Hi,    I've been looking at the code in t

Re: private key not available for client_cert_cb

2020-12-17 Thread Jan Just Keijser
Hi, On 16/12/20 20:26, George wrote: Hi,    I've been looking at the code in the pppd EAP-TLS patch, but I can't seem to load the engine with the pkcs11 DLL. It is failing with the error: error:2507606A:DSO support routines:WIN32_BIND_FUNC:could not bind to the requested symbol name I've

Re: private key not available for client_cert_cb

2020-12-16 Thread George
Hi,    I've been looking at the code in the pppd EAP-TLS patch, but I can't seem to load the engine with the pkcs11 DLL. It is failing with the error: error:2507606A:DSO support routines:WIN32_BIND_FUNC:could not bind to the requested symbol name I've verified the path is correct. I am usi

Re: private key not available for client_cert_cb

2020-12-15 Thread Jan Just Keijser
Hi, On 14/12/20 21:01, George wrote: Ok, so I am not actually going to populate EVP_PKEY with a private key in the callback function: int (*client_cert_cb)(SSL *ssl, X509 **x509, *EVP_PKEY **pkey*)? Instead, I will call EVP_PKEY *ENGINE_load_private_key(ENGINE *e, const char *key_id, UI_METHO

RE: private key not available for client_cert_cb

2020-12-14 Thread Michael Wojcik
> From: openssl-users On Behalf Of George > Sent: Monday, 14 December, 2020 13:01 > Once I get the resulting EVP_PKEY using ENGINE_load_private_key(...), > how do I assign it to pkey in the callback function? I don't know offhand. As I said in my other message, that's not an area I had to get

Re: private key not available for client_cert_cb

2020-12-14 Thread George
Ok, so I am not actually going to populate EVP_PKEY with a private key in the callback function: int (*client_cert_cb)(SSL *ssl, X509 **x509, *EVP_PKEY **pkey*)? Instead, I will call EVP_PKEY *ENGINE_load_private_key(ENGINE *e, const char *key_id, UI_METHOD *ui_method, void *callback_data); to

RE: private key not available for client_cert_cb

2020-12-14 Thread Michael Wojcik
> From: openssl-users On Behalf Of George > Sent: Monday, 14 December, 2020 09:36 > I see what you mean. So once I have everything setup, i use the following > to get the private key: > EVP_PKEY *pkey = ENGINE_load_private_key(...); > > Will pkey actually contain the private key from the smart

Re: private key not available for client_cert_cb

2020-12-14 Thread Paul Nelson
How I did this: 1) You can make up your own EVP_PKEY that uses your own engine implementation and attach a data ptr to it EVP_PKEY* returnPKey; returnPKey = EVP_PKEY_new(); if( returnPKey ) {

Re: private key not available for client_cert_cb

2020-12-14 Thread George
Hi Michael,    I see what you mean. So once I have everything setup, i use the following to get the private key: EVP_PKEY *pkey = ENGINE_load_private_key(pkey_engine, pkey_identifier, transfer_pin, &cb_data); Will pkey actually contain the private key from the smart card? I thought it was no

RE: private key not available for client_cert_cb

2020-12-14 Thread Michael Wojcik
> From: openssl-users On Behalf Of George > Sent: Monday, 14 December, 2020 08:15 > Thanks for your response. It looks like I don't already have the PPP and > PPPD. You don't need PPP to use a smartcard or other PKCS#11 device. Jan just mentioned the source as a exemplar of the interactions

Re: private key not available for client_cert_cb

2020-12-14 Thread George
Hi Jan,    Thanks for your response. It looks like I don't already have the PPP and PPPD. Do I need to download and install the following? https://github.com/jjkeijser/ppp/tree/eap-tls I am using OpenSSL in Windows 10 and compiled it with Visual Studio 2019. Will this EAP-TLS code compile/wor

Re: private key not available for client_cert_cb

2020-12-14 Thread Jan Just Keijser
Hi, On 14/12/20 08:08, George wrote: Hi,    I'm new to OpenSSL and am trying to set up mutual authentication in a client. The client is setup with OpenSSL 1.0.2u. and the client's certificate + private key is stored on a Smart Card.  When the client receives a certificate request from the se

Re: private key in hardware ssl

2013-11-05 Thread andrew cooke
You can write your own engine that calls the routines you have. You can also write a shim library that wraps the library you have and presents it as PKCS#11. Then you can use a PKCS#11 engine. The first approach is easiest but the second gives you more options down the line (you don't need to i

Re: Private Key Format Different in FIPS Mode

2013-06-12 Thread Anamitra Dutta Majumdar (anmajumd)
Also I found that this works fine with openssl 1.0.1 Where keys are generated in FIPS mode with the following line. Can someone let me know why this change in behavior between 0.9.8l and 1.0.1? -BEGIN DSA PRIVATE KEY- Thanks, Anamitra On 6/12/13 12:01 PM, "Anamitra Dutta Majumdar (anma

RE: Private key passphrase: salt question

2013-03-15 Thread Dave Thompson
>From: owner-openssl-us...@openssl.org On Behalf Of Evan Brown >Sent: Wednesday, 13 March, 2013 11:02 >openssl genrsa -aes256 -out private.pem 2048 >Am I correct in my understanding that OpenSSL adds a salt >to the passphrase that I specify when this command runs? >How is the salt computed and w

Re: Private key support at openssl

2013-02-22 Thread Jakob Bohm
On 2/22/2013 9:16 AM, Rajeswari K wrote: Hello Team, We have a requirement to support onboard crypto engine which doesn't share private keys to openssl. Current openssl code requires private keys in its possession to succeed with handshake process. Is there any way to skip updation of private ke

Re: private key extractipon from ecdsapriv.pem file

2012-12-14 Thread jeetendra gangele
I am getting below error when i enable the error tag EC_KEY_check_key failed: 70error:100B1043:elliptic curve routines:EC_KEY_check_key:passed a null parameter Can I load only private part of the key for signing the data? On 14 December 2012 15:34, jeetendra gangele wrote: > HI > I tried the be

Re: private key extractipon from ecdsapriv.pem file

2012-12-14 Thread jeetendra gangele
HI I tried the below code but still failed. below is my keys also ec -in ec_key.pem -noout -text read EC key Private-Key: (224 bit) priv: 00:ca:9e:dd:d8:f0:e0:48:35:2c:f7:82:33:24:61: 78:36:df:0d:83:8f:b6:02:97:b1:e3:29:4e:e4 pub: 04:ca:92:89:e7:00:51:43:28:64:89:e5:ed:36:2e: 65:64

RE: private key extractipon from ecdsapriv.pem file

2012-12-14 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of jeetendra gangele > Sent: Friday, 14 December, 2012 02:59 > I run the below two command and generated the private key for > ecdsa sign . Actually you generated two keypairs and ignored one of them. But what the hey, they're cheap (unlike say l

Re: Private key generation

2011-05-14 Thread Zico
On Sun, May 15, 2011 at 1:55 AM, Larry Bugbee wrote: > > > It is a matter of trust. If your server is serving a very small group that > will trust your self-signed cert, then fine. If however your server is to > be visited by a large number of people most of which won't know you, they > would l

Re: Private key generation

2011-05-14 Thread Larry Bugbee
On May 14, 2011, at 11:54 AM, Zico wrote: > Do we "actually" need a third party to make our certificate? I mean, we can > generate self-certified certificates, right? So, will my production machine > not run if I don't use CAcert.org or GoDaddy or Verisign? It is a matter of trust. If your se

Re: Private key generation

2011-05-14 Thread Zico
On Sat, May 14, 2011 at 8:06 AM, Dave Thompson wrote: > > The latter, as long as you transfer the private key from your machine > to the server along with the certificate from the CA. > > You do need to keep *both* machines (keygen and server) secure > and also the transfer process. It's usually a

RE: Private key generation

2011-05-13 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of Zico > Sent: Friday, 13 May, 2011 06:10 > Hi, is it necessary to generate private from "that server" > in which I will install SSL certificate? I mean, say, I want to > install SSL certificate for my www.mysite.com, now, is i

RE: Private key generation

2011-05-13 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of Zico > Sent: Friday, 13 May, 2011 06:10 > Hi, is it necessary to generate private from "that server" > in which I will install SSL certificate? I mean, say, I want to > install SSL certificate for my www.mysite.com, now, is i

Re: Private Key from Windows Cert Store

2011-01-03 Thread Harshvir Sidhu
nssl.org] On Behalf Of Fili, Tom > Sent: Friday, December 03, 2010 3:48 PM > To: openssl-users@openssl.org > Subject: RE: Private Key from Windows Cert Store > > Ok, I got it loading. Thanks. > > I'm still have an issue, which would stem from my lack of understanding

RE: Private Key from Windows Cert Store

2010-12-08 Thread Fili, Tom
- From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of Fili, Tom Sent: Friday, December 03, 2010 3:48 PM To: openssl-users@openssl.org Subject: RE: Private Key from Windows Cert Store Ok, I got it loading. Thanks. I'm still have an issue, which would stem fr

Re: Private Key from Windows Cert Store

2010-12-08 Thread Harshvir Sidhu
all I have to make? > > Again, thanks. You have been so helpful. > > -Original Message- > From: owner-openssl-us...@openssl.org > [mailto:owner-openssl-us...@openssl.org] On Behalf Of Dr. Stephen Henson > Sent: Friday, December 03, 2010 12:27 PM > To: openssl-users@o

RE: Private Key from Windows Cert Store

2010-12-03 Thread Fili, Tom
openssl-users@openssl.org Subject: Re: Private Key from Windows Cert Store On Fri, Dec 03, 2010, Fili, Tom wrote: > I rebuild OpenSSL and didn't get a capi.dll. I'm using 0.9.8k. Is there > something I'm missing in the build process that I need to change to get > the eng

Re: Private Key from Windows Cert Store

2010-12-03 Thread Mounir IDRASSI
From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of Fili, Tom Sent: Friday, December 03, 2010 12:01 PM To: openssl-users@openssl.org Subject: RE: Private Key from Windows Cert Store I rebuild OpenSSL and didn't get a capi.dll. I'm using 0.9.8k. Is there s

Re: Private Key from Windows Cert Store

2010-12-03 Thread Dr. Stephen Henson
On Fri, Dec 03, 2010, Fili, Tom wrote: > I rebuild OpenSSL and didn't get a capi.dll. I'm using 0.9.8k. Is there > something I'm missing in the build process that I need to change to get > the engines to compiled in. From what I've read it looks like it builds > these engines into the openssl dlls

RE: Private Key from Windows Cert Store

2010-12-03 Thread Fili, Tom
Of Fili, Tom Sent: Friday, December 03, 2010 12:01 PM To: openssl-users@openssl.org Subject: RE: Private Key from Windows Cert Store I rebuild OpenSSL and didn't get a capi.dll. I'm using 0.9.8k. Is there something I'm missing in the build process that I need to change to get the engines

RE: Private Key from Windows Cert Store

2010-12-03 Thread Fili, Tom
November 30, 2010 11:49 AM To: openssl-users@openssl.org Subject: Re: Private Key from Windows Cert Store On Tue, Nov 30, 2010, Fili, Tom wrote: > Thanks, but I was more looking for docs on the interop of OpenSSL and > the Crypto API. I got pretty most info from the capi that I needed > excep

Re: Private Key from Windows Cert Store

2010-11-30 Thread Dr. Stephen Henson
On Tue, Nov 30, 2010, Fili, Tom wrote: > Thanks, but I was more looking for docs on the interop of OpenSSL and > the Crypto API. I got pretty most info from the capi that I needed > except the private key, which from what I've read may not always be > exportable anyway. I was looking for how to ca

Re: Private Key from Windows Cert Store

2010-11-30 Thread Harshvir Sidhu
load as I get NULL from ENGINE_by_id("capi"); > > -Original Message- > From: owner-openssl-us...@openssl.org [ > mailto:owner-openssl-us...@openssl.org ] > On Behalf Of Stef Hoeben > Sent: Sunday, November 28, 2010 12:58 PM > To: openssl-users@openssl.org >

RE: Private Key from Windows Cert Store

2010-11-30 Thread Fili, Tom
I get NULL from ENGINE_by_id("capi"); -Original Message- From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of Stef Hoeben Sent: Sunday, November 28, 2010 12:58 PM To: openssl-users@openssl.org Subject: RE: Private Key from Windows Cert Store Hi T

RE: Private Key from Windows Cert Store

2010-11-28 Thread Stef Hoeben
sl-users@openssl.org > Subject: RE: Private Key from Windows Cert Store > > Is there a place that has some docs or examples of the capi API? I've > looked around, but haven't found any good source for these. > > Tom Fili > Software Engineer > Analytical Graphics In

RE: Private Key from Windows Cert Store

2010-11-28 Thread Fili, Tom
/26/2010 4:35 AM To: openssl-users@openssl.org Subject: Re: Private Key from Windows Cert Store I think you may use the CAPI engine instead. 2010/11/24 Fili, Tom > I'm trying to load a private key file of a personal cert from a key file > and load it like so: > > SSL_CTX_use_

Re: Private Key from Windows Cert Store

2010-11-26 Thread So Gerald
I think you may use the CAPI engine instead. 2010/11/24 Fili, Tom > I'm trying to load a private key file of a personal cert from a key file > and load it like so: > > SSL_CTX_use_PrivateKey_file(pSSLContext, privateKeyFile, SSL_FILETYPE_PEM) > > However the certificate is in the Windows Certif

Re: [openssl-users] Re: Private Key Usage Period

2010-05-19 Thread Erwann ABALEA
Hodie XIV Kal. Iun. MMX, Dr. Stephen Henson scripsit: > On Wed, May 19, 2010, Eisenacher, Patrick wrote: > > > Hi Bram, > > > > > -Original Message- > > > From: Bram Cymet > > > > > > I am wondering if with the latest version of Openssl it is possible to > > > set the Private Key Usage Pe

Re: Private Key Usage Period

2010-05-19 Thread Dr. Stephen Henson
On Wed, May 19, 2010, Eisenacher, Patrick wrote: > Hi Bram, > > > -Original Message- > > From: Bram Cymet > > > > I am wondering if with the latest version of Openssl it is possible to > > set the Private Key Usage Period extension and if so what is > > the format > > of the parameters? >

RE: Private Key Usage Period

2010-05-19 Thread Eisenacher, Patrick
Hi Bram, > -Original Message- > From: Bram Cymet > > I am wondering if with the latest version of Openssl it is possible to > set the Private Key Usage Period extension and if so what is > the format > of the parameters? this is how I do it in my config file: [ ca_ext ] basicConstraints

Re: Private key/CA key

2009-09-19 Thread Goetz Babin-Ebell
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Donald Beck wrote: | I am a bit new to this, so I need a little help. | | I created my own CA using openssl and I just want to make sure I have | this right. I imported my signed certificate on my server from the | request I created from my server.

RE: Private Key Length

2007-11-02 Thread Dave Thompson
> From: owner-openssl-users On Behalf Of Pierce Ward > Sent: Wednesday, 31 October, 2007 09:07 > openssl genrsa -out private_key.pem -f4 768 > openssl pkcs8 -in private_key.pem -nocrypt -topk8 -out PK.pem > cat PK.pem | openssl enc -base64 -d > PK.key You don't need a separate step there; just

Re: Private Key problem

2007-05-03 Thread alois74
Original-Nachricht Datum: Thu, 3 May 2007 12:20:28 +0200 Von: "Dr. Stephen Henson" <[EMAIL PROTECTED]> An: openssl-users@openssl.org Betreff: Re: Private Key problem > On Thu, May 03, 2007, [EMAIL PROTECTED] wrote: > > > Thanks! > > I cur

Re: Private Key problem

2007-05-03 Thread Dr. Stephen Henson
On Thu, May 03, 2007, [EMAIL PROTECTED] wrote: > Thanks! > I currently dont have access to the key generator, so cant post an example. > However, the key actually DOES start with 30. > The first chars are: > 30820 > the last ones are: > F750 > > then theres a newline at the end. i tried removing

Re: RE: Private Key problem

2007-05-03 Thread alois74
again alois Original-Nachricht Datum: Wed, 2 May 2007 17:44:14 -0700 Von: "David Schwartz" <[EMAIL PROTECTED]> An: openssl-users@openssl.org Betreff: RE: Private Key problem > > > Ok, so i guess i do somehow have to convert that hex data into > > binar

Re: Private Key problem

2007-05-03 Thread alois74
Thanks! I currently dont have access to the key generator, so cant post an example. However, the key actually DOES start with 30. The first chars are: 30820 the last ones are: F750 then theres a newline at the end. i tried removing that, ..same. anyway, im pretty confused. No idea what else i coul

RE: Private Key problem

2007-05-02 Thread David Schwartz
> Ok, so i guess i do somehow have to convert that hex data into > binary, right? > i tried to do this with xxd, but i cant seem to find the option i > need. i pasted the output of -help for xxd below. I tried: > xxd -r infile outfile > but had to learn that a hexdump is not quite what my key is .

Re: Private Key problem

2007-05-02 Thread Dr. Stephen Henson
On Wed, May 02, 2007, [EMAIL PROTECTED] wrote: > (openssl-dev readers ignore, crosspost...) > > Hey all, > > Im tearing my hair out here with what is probably a stupid problem. > I'm new to openssl , rsa, etc... , so bear with me please:) > > Im doing the server-side things of an authorization

RE: Private Key Type and PEM Length

2006-07-04 Thread Wu, Sonia X (Sonia)
Got it. Thanks. Sonia -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marek Marcola Sent: Tuesday, July 04, 2006 3:48 AM To: openssl-users@openssl.org Subject: RE: Private Key Type and PEM Length Hello, > One more question before I move to new age

RE: Private Key Type and PEM Length

2006-07-04 Thread Marek Marcola
Hello, > One more question before I move to new agenda. > Is siglen RSA_size? Should rsa_pv and rsa_pb the same size? Yes, and this is size of modulus, RSA_size simply returns BN_num_bytes(rsa->n); Best regards, -- Marek Marcola <[EMAIL PROTECTED]> __

RE: Private Key Type and PEM Length

2006-07-03 Thread Wu, Sonia X (Sonia)
same size? Thanks again. Sonia -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marek Marcola Sent: Monday, July 03, 2006 2:13 PM To: openssl-users@openssl.org Subject: RE: Private Key Type and PEM Length Hello, > This is what I up to, > >

RE: Private Key Type and PEM Length

2006-07-03 Thread Marek Marcola
Hello, > This is what I up to, > > $ openssl genrsa -out private.pem 2048 > $ openssl rsa -in private.pem -out public.pem -pubout > > to gen the private & public keys > > pvk_fd = fopen("private.pem","r"); > rsa_pv = PEM_read_RSAPrivateKey(pvk_fd,&rsa_pv,NULL,NULL); > ret = RSA_sign(NID_md5,tes

RE: Private Key Type and PEM Length

2006-07-03 Thread Wu, Sonia X (Sonia)
keys, they are the same. RSA_sign/verify does not work. What did I miss? Thanks. Sonia -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Marek Marcola Sent: Monday, July 03, 2006 8:57 AM To: openssl-users@openssl.org Subject: RE: Private Key Type and PEM Len

RE: Private Key Type and PEM Length

2006-07-03 Thread Marek Marcola
Hello, > I want to read public part of RSA. > The input file is PEM format file generated by openssl genrsa > for private and openssl rsa for public. > Do you mean this is not the correct format for PEM_read_RSAPublicKey? Yes, PEM_read_RSAPublicKey require PKCS#1 but if public key was generated w

RE: Private Key Type and PEM Length

2006-07-03 Thread Wu, Sonia X (Sonia)
] Behalf Of Marek Marcola Sent: Monday, July 03, 2006 8:25 AM To: openssl-users@openssl.org Subject: RE: Private Key Type and PEM Length Hello, > I tried the PEM_read_RSAPrivateKey and PEM_read_RSAPublicKey pair. > PEM_read_RSAPrivateKey seems work fine. > PEM_read_RSAPublicKey failed. >

RE: Private Key Type and PEM Length

2006-07-03 Thread Marek Marcola
Hello, > I tried the PEM_read_RSAPrivateKey and PEM_read_RSAPublicKey pair. > PEM_read_RSAPrivateKey seems work fine. > PEM_read_RSAPublicKey failed. > By tracing, it failed in BIO_gets(), returning 0. Any idea? PEM_read_RSAPublicKey reads from PKCS#1 ASN1 structure public part of RSA key (n,e).

RE: Private Key Type and PEM Length

2006-07-03 Thread Wu, Sonia X (Sonia)
:[EMAIL PROTECTED] Behalf Of Marek Marcola Sent: Friday, June 30, 2006 10:01 AM To: openssl-users@openssl.org Subject: RE: Private Key Type and PEM Length Hello, > I am working on something similar. if I generated a private key with no > password, > can I pass NULL to PEM_read_bio_privateKey(

Re: Private Key Type and PEM Length

2006-07-03 Thread Sudhir Voona
Thanks Marek,I Got the function Wanted !!--sudhir

Re: Private Key Type and PEM Length

2006-07-03 Thread Marek Marcola
Hello, > I think the modulus field of the rsa_t / dsa_t structure gives the > Key Length in Bytes, > am i correct ?? Oh, you mean size of RSA key, try RSA_size(); (and yes - this is size of modulus) Best regards, -- Marek Marcola <[EMAIL PROTECTED]> __

Re: Private Key Type and PEM Length

2006-07-03 Thread Sudhir Voona
Hi,     I think the modulus field of the rsa_t / dsa_t structure gives the Key Length in Bytes,    am i correct ??--SudhirOn 7/3/06, Sudhir Voona <[EMAIL PROTECTED]> wrote: Hi,   Thanks for the suggestion Marek.   As posted earlier, my requirement is to know the Private Key Type and its PEM Length

Re: Private Key Type and PEM Length

2006-07-03 Thread Sudhir Voona
Hi,   Thanks for the suggestion Marek.   As posted earlier, my requirement is to know the Private Key Type and its PEM Length.   EVP_PKEY would give me  the private key Type and not its PEM Length.   How do i extract the PEM Length of the EVP_PKEY  ?     Is there an API for getting the   EVP_PKEY

RE: Private Key Type and PEM Length

2006-06-30 Thread Marek Marcola
Hello, > I am working on something similar. if I generated a private key with no > password, > can I pass NULL to PEM_read_bio_privateKey(bio,&pkey,NULL,NULL)? Yes, > Is there lib function that reads DER format? Try d2i_RSAPrivateKey_bio(); Best regards, -- Marek Marcola <[EMAIL PROTECTED]> _

RE: Private Key Type and PEM Length

2006-06-30 Thread Wu, Sonia X (Sonia)
arek Marcola Sent: Thursday, June 29, 2006 6:52 AM To: openssl-users@openssl.org Subject: Re: Private Key Type and PEM Length Hello, > > Can anyone tell me how to get the Private Key Type(DSA /RSA ) and its > > PEM Length given the buffer containing the Private Key in PEM / DER > >

Re: Private Key Type and PEM Length

2006-06-29 Thread Marek Marcola
Hello, > > Can anyone tell me how to get the Private Key Type(DSA /RSA ) and its > > PEM Length given the buffer containing the Private Key in PEM / DER > > format. > If you have buffer in PEM format, key tape can be read from > first "line" (for example: -BEGIN DSA PRIVATE KEY-) > > If y

Re: Private Key Type and PEM Length

2006-06-29 Thread Marek Marcola
Hello, > I am sending my Query again .. > > Is there any OpenSSL API which would give me the Key Type and its PEM > Length if I pass the buffer containing the Private Key in DER /PEM > format to it ?? > > Can anyone tell me how to get the Private Key Type(DSA /RSA ) and its > PEM Length given th

Re: Private key from Java to OpenSSL

2002-01-13 Thread Dr S N Henson
Tomas Anderson wrote: > > > I have a java keystore and want to export the private > key and certificate (Verisign 128-bits) in it for use > with Apache (we are changing server from a java-based > server to Apache (mod_ssl)). Apache works like a dream > when tested (compared to java.) with O

Re: Private key in exernal hardware (engine) ?

2001-12-13 Thread Richard Levitte - VMS Whacker
From: "Alexander Kuit" <[EMAIL PROTECTED]> AKuit> On 13.12.2001 16:45:15 Richard Levitte - VMS Whacker wrote: AKuit> [...] AKuit> >AKuit> I don't have and need access to the private key in the card, I only AKuit> >AKuit> have to make sure the right key is used during the SSL handshake, AKuit> >A

Re: Private key in exernal hardware (engine) ?

2001-12-13 Thread Alexander Kuit
On 13.12.2001 16:45:15 Richard Levitte - VMS Whacker wrote: >What you're talking about below is something different than what I >answered above. Ok, this seems to be going into the wrong direction, but that's probably my own fault. Let me put some things straight. >Ah. Well, the very simple a

Re: Private key in exernal hardware (engine) ?

2001-12-13 Thread Götz Babin-Ebell
Alexander Kuit wrote: > > On 13.12.2001 10:49:31 Richard Levitte - VMS Whacker wrote: > > >Assuming you have reached a point where you have a RSA that contains > >the public data in a form that OpenSSL understands, and a reference > >(completely chosen by you) to the private data on the card in

Re: Private key in exernal hardware (engine) ?

2001-12-13 Thread Richard Levitte - VMS Whacker
From: "Alexander Kuit" <[EMAIL PROTECTED]> AKuit> On 13.12.2001 10:49:31 Richard Levitte - VMS Whacker wrote: AKuit> [...] AKuit> >This is exactly how it's done in crypto/engine/hw_ncipher.c, why don't AKuit> >you take a look at that file? AKuit> AKuit> Hi Richard, AKuit> AKuit> I had a look a

Re: Private key in exernal hardware (engine) ?

2001-12-13 Thread Alexander Kuit
On 13.12.2001 10:49:31 Richard Levitte - VMS Whacker wrote: >Assuming you have reached a point where you have a RSA that contains >the public data in a form that OpenSSL understands, and a reference >(completely chosen by you) to the private data on the card in ex_data, >you can now do the follo

Re: Private key in exernal hardware (engine) ?

2001-12-12 Thread Götz Babin-Ebell
Alexander Kuit wrote: > > On 12.12.2001 11:12:35 Vadim Fedukovich wrote: > > >On Wed, 12 Dec 2001, Alexander Kuit wrote: > > > >> > >> >> I'm using the engine version to let the client do rsa private encryption > >> >> by a smartcard. This means of course that the private key is hidden > >> >> i

Re: Private key in exernal hardware (engine) ?

2001-12-12 Thread Alexander Kuit
On 12.12.2001 11:12:35 Vadim Fedukovich wrote: >On Wed, 12 Dec 2001, Alexander Kuit wrote: > >> >> >> I'm using the engine version to let the client do rsa private encryption >> >> by a smartcard. This means of course that the private key is hidden >> >> inside the card. However, during debuggin

Re: Private key in exernal hardware (engine) ?

2001-12-12 Thread Richard Levitte - VMS Whacker
From: "Alexander Kuit" <[EMAIL PROTECTED]> AKuit> As far as I understand this function, it requests the private key from the AKuit> engine. Unfortunately (but not surprisingly), the private key is inside AKuit> the smartcard and cannot be read (only selected for cryptographic AKuit> operations).

Re: private key and certificate to the CA

2001-11-13 Thread Dr S N Henson
Francisco Castillejo wrote: > > Very Thanks!! XD > i didn't know that i was using the default config file located into > /usr/local > in windows the openssl.cnf file is in the subdirectory apps . > Finally i execute: > req -new -x509 -config c:\openssl\apps\openssl.cnf -out CAcert.pem -keyou

Re: private key and certificate to the CA

2001-11-13 Thread Francisco Castillejo
s :) Lidia - Original Message - From: "Neff Robert A" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, November 13, 2001 9:02 PM Subject: RE: private key and certificate to the CA > Since you didn't specify the -config option, you are using the &g

RE: private key and certificate to the CA

2001-11-13 Thread Neff Robert A
Since you didn't specify the -config option, you are using the default config file with a location of /usr/local/ssl/openssl.cnf. That directory doesn't exist in Windows. A simple solution is to place the following into a .bat file in your openssl\ms directory, and run it from that directory: se

Re: private key

2001-08-22 Thread Fiel Cabral
Thanks. I looked at the asn1parse output and found that d2i_RSAPrivateKey() expected an INTEGER for the version number in the ASN1.DER file but it read something else so it exited. --- Dr S N Henson <[EMAIL PROTECTED]> wrote: > Fiel Cabral wrote: > > > > I'm writing a program that uses openssl t

Re: private key

2001-08-21 Thread Dr S N Henson
Fiel Cabral wrote: > > I'm writing a program that uses openssl to read the > private key from a ASN1.DER encoded file. The openssl > API outputs the following: > > 17752:error:0D080071::lib(13) :func(128) > :reason(113):a_int.c:191: > 17752:error:0D09D082::lib(13) :func(157) > :reason(130):d2i_r

Re: Private key migration

2001-02-27 Thread Dr S N Henson
Gil Schindler wrote: > > Hi, > > Since I missed one detail, I am talking about migration from IIS and > Netscape to Apache > IIS: read the rsa(1) manual page for OpenSSL. Netscape Web server. Older versions: check my home site. Newer versions you can copy and rename the databases to a form

RE: Private key migration

2001-02-27 Thread Gil Schindler
] Subject:Re: Private key migration 1) ftp. 2) ssh. 3) floppy disk. 4) theft and deposit by a friendly hacker. 5) ... But the real answer to your question is probably a function of what the two webservers in question are, which you neglected to mention

Re: Private key migration

2001-02-27 Thread Greg Stark
1) ftp. 2) ssh. 3) floppy disk. 4) theft and deposit by a friendly hacker. 5) ... But the real answer to your question is probably a function of what the two webservers in question are, which you neglected to mention. Private keys maybe protected by proprietary password schemes, and/or stored in

  1   2   >