Try if below works for you:

unsigned char buf[] = "----- BEGIN CERTIFICATE ----- ... ----- END CERTIFICATE -----"; /* copy the entire certificate file (PEM formatted) and stick it in here */

BIO *bio = NULL;
X509 *x509 = NULL;

bio = BIO_new_mem_buf(buf, -1);
x509 = PEM_read_bio_X509(bio, NULL, NULL, NULL);

-Tan Eng Ten

James Whitwell wrote:
Hi,

Can anyone tell me if it's possible to embed a client certificate inside my executable, and what calls I should use to tell OpenSSL to use it? I think I'll also need to do it for the CA, since we use self-signed certificates, and I want the client to verify the server's certificate too.

Thanks,
;) james.
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]


______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to