Hello,
> Suppose I have a "Singleton" class below. This method is shared by
> multithreads. This class returns a one and only one ctx ( One Context
> which shares by multithreads). For me, the only Mutex Lock I need is
> around line  8 because of verify_callback method. The remain methods are
> read only
OpenSSL needs internal locks when running in multithreaded environment.
You should set proper locking callback functions when initializing
OpenSSL. There are examples in thread:

http://www.nabble.com/When-to-use-CRYPTO_set_locking_callback%28%
29-and-CRYPTO_set_id_callback%28%29--tf2121027.html#a5849882

Best regards,
-- 
Marek Marcola <[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