Dear OpenSSL development team,

        I have some questions on the formats accept by OpenSSL programming 
interface in C/C++. The functions

 

                            int SSL_CTX_use_PrivateKey_file(SSL_CTX *ctx, const 
char *file, int type);

              int SSL_CTX_use_certificate_file(SSL_CTX *ctx, const char *file, 
int type);

 

accept two possible options for the type of the file,

 

#define SSL_FILETYPE_ASN1     X509_FILETYPE_ASN1

#define SSL_FILETYPE_PEM      X509_FILETYPE_PEM

 

I would like to know:

 

1) Is there a C/C++ interface to directly read certificates in PKCS12 format? I 
understand that one can use OpenSSL command line to take PKCS12 and convert it, 
say, to PEM so that we could use the original function, but I need to know if 
it is possible to read PKCS12 directly, without creating a converted copy?

 

2) Are the above two the only certificate formats directly accepted by C/C++ 
interface?

 

3) We normally use PEM, I am not sure about ASN1, is it kind of obsolete or for 
backward compatibility?

 

Thank you very much,

 

Vladimir Shklover,

SPSS

 

Reply via email to