Hopefully this is helpful for people coming across this thread, as some information on the web explicitly states that openssl doesn't have notification callbacks, which may have put you on a wrong track.
SSL_CTX_set_info_callback() sets the callback function, that can be used to obtain state information for SSL objects created from ctx during connection setup and use.