]> git.proxmox.com Git - mirror_kronosnet.git/commit
[openssl] fix openssl1.0 crash by implementing documented locking callbacks
authorFabio M. Di Nitto <fdinitto@redhat.com>
Tue, 2 Jan 2018 16:23:02 +0000 (17:23 +0100)
committerFabio M. Di Nitto <fdinitto@redhat.com>
Tue, 2 Jan 2018 16:23:02 +0000 (17:23 +0100)
commit82a7bc3d3c5824c3d0ece85ce3792eca11578e5c
treedcbafe5d6bddebb18db2f678a7ade20b70846fd7
parent4d3686398d6686fdc93596db8af92904ead740cd
[openssl] fix openssl1.0 crash by implementing documented locking callbacks

openssl < 1.1.0 do not support natively multithread applications and need
some extra help from the application itself to provide locking callbacks.

https://www.openssl.org/docs/man1.0.2/crypto/threads.html
https://www.openssl.org/blog/blog/2017/02/21/threads/

to test this fix is necessary to use knet_bench or corosync with openssl
and lots of heavy load (perf benchmark) workload. Sooner or later
the application will crash with some random tracebacks.

after this patch, the crash cannot be reproduced anymore.

tested using 9 nodes x2 active/active links all running corosync + cpghum

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
libknet/crypto_openssl.c