openssl: Whitelist OPENSSL_init_crypto() and others in leak detective
authorTobias Brunner <tobias@strongswan.org>
Mon, 27 Jun 2016 15:44:57 +0000 (17:44 +0200)
committerTobias Brunner <tobias@strongswan.org>
Wed, 29 Jun 2016 09:09:38 +0000 (11:09 +0200)
Lots of static data is allocated in this function, which isn't freed until
the library is unloaded (we can't call OPENSSL_cleanup() as initialization
would fail when calling it again later).  When enabling the leak
detective the test runner eventually crashes as all the data allocated during
initialization has an invalid size when freed after leak detective has been
unloaded.

src/libstrongswan/utils/leak_detective.c

index a0bdae7..aeadc0c 100644 (file)
@@ -564,6 +564,10 @@ char *whitelist[] = {
        "ECDSA_do_sign_ex",
        "ECDSA_verify",
        "RSA_new_method",
+       /* OpenSSL 1.1.0 does not cleanup anymore until the library is unloaded */
+       "OPENSSL_init_crypto",
+       "CRYPTO_THREAD_lock_new",
+       "ERR_add_error_data",
        /* OpenSSL libssl */
        "SSL_COMP_get_compression_methods",
        /* NSPR */