[openssl-users] Regarding server side sessions support

Sahib Jakhar sahib.jakhar at gmail.com
Wed Mar 25 15:27:31 UTC 2015


Hi,

I am trying to implement server side caching support for sessions by
using callback functions. However, the callback functions are never
being called, even though connection happens successfully without
session resumption. For your reference some of the sample code I am
pasting below:

ssl_session_ctx_id = 1;
SSL_CTX_set_session_id_context (c, (void *)&ssl_session_ctx_id, sizeof
(ssl_session_ctx_id));
SSL_CTX_set_session_cache_mode(c, SSL_SESS_CACHE_SERVER |
SSL_SESS_CACHE_NO_INTERNAL);
SSL_CTX_sess_set_new_cb (c, custom_new_session_cb );
SSL_CTX_sess_set_remove_cb (c, custom_remove_session_cb );
SSL_CTX_sess_set_get_cb (c, custom_get_session_cb);


Can somebody kindly help me as to what I am missing out here? What
could be the reason behind the callback functions not being called?


Thanks
Sahib


More information about the openssl-users mailing list