Hi,
 
I develop a multithreaded application that would benefit from adding a
userdata argument to the callback functions that you can set using the
following openssl functions:
SSL_CTX_set_tmp_rsa_callback
SSL_CTX_set_verify 
 
Currently I have to set thread specific data and look up the session
variable every time the callback functions are called.
I think it would be much better if there was a possibility to set a
userdata argument that was supplied by openssl when the callbacks were
called.
 
Current usage:
---------------------
static int ssl_open_verify (int ok,X509_STORE_CTX *ctx); /* function
uses Thread local storage to lookup application userdata */
static RSA *ssl_genkey (SSL *con,int export,int keylength); /* function
uses Thread local storage to lookup application userdata */

 SSL_CTX_set_tmp_rsa_callback (context,ssl_genkey);
 SSL_CTX_set_verify (context,SSL_VERIFY_PEER,ssl_open_verify);

If enhancement implemented:
----------------------------------------
static int ssl_open_verify (int ok,X509_STORE_CTX *ctx, void *userdata);
static RSA *ssl_genkey (SSL *con,int export,int keylength, void
*userdata);

 SSL_CTX_set_tmp_rsa_callback_userdata (context,ssl_genkey, userdata);
 SSL_CTX_set_verify_userdata (context,SSL_VERIFY_PEER,ssl_open_verify,
userdata);

Best regards,
Thomas Nilsson
Software Engineer, StreamServe
 

Hi,
 
I develop a multithreaded application that would benefit from adding a userdata argument to the callback functions that you can set using the following openssl functions:
SSL_CTX_set_tmp_rsa_callback
SSL_CTX_set_verify
 
Currently I have to set thread specific data and look up the session variable every time the callback functions are called.
I think it would be much better if there was a possibility to set a userdata argument that was supplied by openssl when the callbacks were called.
 
Current usage:
---------------------
static int ssl_open_verify (int ok,X509_STORE_CTX *ctx); /* function uses Thread local storage to lookup application userdata */
static RSA *ssl_genkey (SSL *con,int export,int keylength); /* function uses Thread local storage to lookup application userdata */

 SSL_CTX_set_tmp_rsa_callback (context,ssl_genkey);
 SSL_CTX_set_verify (context,SSL_VERIFY_PEER,ssl_open_verify);
If enhancement implemented:
----------------------------------------
static int ssl_open_verify (int ok,X509_STORE_CTX *ctx, void *userdata);
static RSA *ssl_genkey (SSL *con,int export,int keylength, void *userdata);

 SSL_CTX_set_tmp_rsa_callback_userdata (context,ssl_genkey, userdata);
 SSL_CTX_set_verify_userdata (context,SSL_VERIFY_PEER,ssl_open_verify, userdata);
Best regards,
Thomas Nilsson
Software Engineer, StreamServe
 

Reply via email to