RE: SSL_CTX_use_PrivateKey_file does not work with Elliptic Curve Private Key
http://www.openssl.org/support/faq.html#PROG6 and if you haven't loaded error strings http://www.openssl.org/support/faq.html#PROG7 From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of Darshan Mody Sent: Monday, May 19, 2014 09:13 To: openssl-users@openssl.org Subject: SSL_CTX_use_PrivateKey_file does not work with Elliptic Curve Private Key Hi, I am new to openssl APIs. However I am using the current code from SIPp. Below is the code snippet for the Private Key if ( SSL_CTX_use_PrivateKey_file(sip_trp_ssl_ctx_client, tls_key_name, SSL_FILETYPE_PEM ) != 1 ) { ERROR("FI_init_ssl_context: SSL_CTX_use_PrivateKey_file (client) failed"); return SSL_INIT_ERROR; } When I provide the Elliptic Private Key it always returns an Error. -BEGIN EC PARAMETERS- -END EC PARAMETERS- -BEGIN EC PRIVATE KEY- -END EC PRIVATE KEY- My Private key looks as above Thanks Darshan
Re: SSL_CTX_use_PrivateKey_file does not work with Elliptic Curve Private Key
On 19/05/14 14:12, Darshan Mody wrote: > -BEGIN EC PARAMETERS- > > -END EC PARAMETERS- > -BEGIN EC PRIVATE KEY- > > -END EC PRIVATE KEY- > > My Private key looks as above How did you generate your private key? Try deleting the EC PARAMETERS section in the file. Matt __ OpenSSL Project http://www.openssl.org User Support Mailing Listopenssl-users@openssl.org Automated List Manager majord...@openssl.org
SSL_CTX_use_PrivateKey_file does not work with Elliptic Curve Private Key
Hi, I am new to openssl APIs. However I am using the current code from SIPp. Below is the code snippet for the Private Key if ( SSL_CTX_use_PrivateKey_file(sip_trp_ssl_ctx_client, tls_key_name, SSL_FILETYPE_PEM ) != 1 ) { ERROR("FI_init_ssl_context: SSL_CTX_use_PrivateKey_file (client) failed"); return SSL_INIT_ERROR; } When I provide the Elliptic Private Key it always returns an Error. -BEGIN EC PARAMETERS- -END EC PARAMETERS- -BEGIN EC PRIVATE KEY- -END EC PRIVATE KEY- My Private key looks as above Thanks Darshan