On Tue, Aug 13, 2013, Joshua Miller wrote: > Hello OpenSSL, > > I am attempting to encrypt a data stream with multiple threads calling > EVP_CipherUpdate. I have set the thread_id and call_back functions as > defined by the API. These functions are never being called, however. I've > used CRYPTO_get_locking_callback() to verify that my function has been set > correctly. > > Everything works correctly when the threads are serialized, but not when > created concurrently. The main goal is to run EVP_CipherUpdate() on a large > amount of data on many threads. > > It seems to me that this should be working, can you tell me what I have done > wrong? >
It depends on what you are trying to do. If you've several threads using the same EVP_CIPHER_CTX that wont work in general as partial blocks get saved in internal buffers and one thread could overwrite a partial block from another. Steve. -- Dr Stephen N. Henson. OpenSSL project core developer. Commercial tech support now available see: http://www.openssl.org ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List [email protected] Automated List Manager [email protected]
