]> git.ipfire.org Git - thirdparty/pdns.git/commit
auth: Properly finalize PKCS11 modules before releasing them 14029/head
authorRemi Gacogne <remi.gacogne@powerdns.com>
Tue, 2 Apr 2024 14:20:14 +0000 (16:20 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 4 Apr 2024 08:32:20 +0000 (10:32 +0200)
commit3c6d9aacd96a099e450545a21020fa8efec9538b
treec224043f83db8f141570b11eb8bbf89822f73f8d
parente472f314a4adfc357d8917de361aded0aabee39f
auth: Properly finalize PKCS11 modules before releasing them

This gets rid of two leaks reported by LeakSanitizer when running our
unit tests:
```
Direct leak of 48 byte(s) in 1 object(s) allocated from:
    #0 0x5fe6c6e7d099 in malloc (/pdns/pdns/testrunner+0x220099) (BuildId: 08d4c369b5f2f19f183aa5d6ab931a6653b70ab9)
    #1 0x7e6cdc6a0964  (/usr/lib/libp11-kit.so.0+0x36964) (BuildId: 307da6c0b5c7d87a1b0fd0a63e0bda93c9375e8a)
    Indirect leak of 72 byte(s) in 1 object(s) allocated from:
    #0 0x5fe6c6e7d401 in calloc (/pdns/pdns/testrunner+0x220401) (BuildId: 08d4c369b5f2f19f183aa5d6ab931a6653b70ab9)
    #1 0x7e6cdc6a09b6  (/usr/lib/libp11-kit.so.0+0x369b6) (BuildId: 307da6c0b5c7d87a1b0fd0a63e0bda93c9375e8a)
```
pdns/pkcs11signers.cc