From c064a5288ece8fb4f3780ac3a1810ac00871e4a6 Mon Sep 17 00:00:00 2001 From: Tobias Brunner Date: Wed, 8 Aug 2018 11:41:36 +0200 Subject: [PATCH] leak-detective: Whitelist some Botan functions Due to the mangled C++ function names it's tricky to be more specific. The "leaked" allocations are from a static hashtable containing EC groups. There is another leak caused by the locking allocator singleton (triggered by the first function that uses it, usually initialization of a cipher, but could be a hasher in other test runners), but we can avoid that with a Botan config option. --- src/libstrongswan/utils/leak_detective.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/libstrongswan/utils/leak_detective.c b/src/libstrongswan/utils/leak_detective.c index b873e12a8c..08fcc0ef04 100644 --- a/src/libstrongswan/utils/leak_detective.c +++ b/src/libstrongswan/utils/leak_detective.c @@ -609,6 +609,11 @@ static char *whitelist[] = { /* FHH IMCs and IMVs */ "TNC_IMC_NotifyConnectionChange", "TNC_IMV_NotifyConnectionChange", + /* Botan */ + "botan_public_key_load", + "botan_privkey_create_ecdsa", + "botan_privkey_create_ecdh", + "botan_privkey_load_ecdh", }; /** -- 2.47.2