hangs with active p11-kit modules

Sven Geggus sven at gegg.us
Tue Aug 14 11:39:37 CEST 2012


Hello,

I encounter strange hangs on various pieces of software (cups, mutt, ...)
linked against gnutls (2.12.x) with an active pkcs11 smartcard module. This
module is not used by these applications, they are just linked against
gnutls.

This goes this far that building gnutls with an active pkcs11 module takes
ages because of very long delays in various gnutls self-tests and after some
very long delay in almost every single test the build fails with the following messages:


make[4]: Entering directory `/home/geg/tmp/gnutls26-2.12.20/tests/safe-renegotiation'
Self test `./srn0' finished with 0 errors
==22313== 4 bytes in 1 blocks are definitely lost in loss record 2 of 33
==22313==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22313==    by 0x55EF881: strdup (strdup.c:43)
==22313==    by 0x536717B: p11_kit_registered_module_to_name (in /usr/lib/libp11-kit.so.0.0.0)
==22313==    by 0x4E76D04: gnutls_pkcs11_init (pkcs11.c:462)
==22313==    by 0x4E5D23A: gnutls_global_init (gnutls_global.c:252)
==22313==    by 0x4012CA: doit (srn0.c:102)
==22313==    by 0x4018E4: main (utils.c:149)
==22313== 
==22313== 252,824 (8,232 direct, 244,592 indirect) bytes in 1 blocks are definitely lost in loss record 33 of 33
==22313==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22313==    by 0x68BA49B: ???
==22313==    by 0x68BC248: ???
==22313==    by 0x68BC483: ???
==22313==    by 0x68B9FE4: ???
==22313==    by 0x685D550: ???
==22313==    by 0x6874C1F: ???
==22313==    by 0x68A4C5D: ???
==22313==    by 0x5366AD4: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22313==    by 0x536785B: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22313==    by 0x5367E8B: p11_kit_initialize_registered (in /usr/lib/libp11-kit.so.0.0.0)
==22313==    by 0x4E76CCD: gnutls_pkcs11_init (pkcs11.c:448)
==22313== 
FAIL: srn0
Self test `./srn1' finished with 0 errors
==22328== 4 bytes in 1 blocks are definitely lost in loss record 2 of 33
==22328==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22328==    by 0x55EF881: strdup (strdup.c:43)
==22328==    by 0x536717B: p11_kit_registered_module_to_name (in /usr/lib/libp11-kit.so.0.0.0)
==22328==    by 0x4E76D04: gnutls_pkcs11_init (pkcs11.c:462)
==22328==    by 0x4E5D23A: gnutls_global_init (gnutls_global.c:252)
==22328==    by 0x40121A: doit (srn1.c:101)
==22328==    by 0x4016F4: main (utils.c:149)
==22328== 
==22328== 252,824 (8,232 direct, 244,592 indirect) bytes in 1 blocks are definitely lost in loss record 33 of 33
==22328==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22328==    by 0x68BA49B: ???
==22328==    by 0x68BC248: ???
==22328==    by 0x68BC483: ???
==22328==    by 0x68B9FE4: ???
==22328==    by 0x685D550: ???
==22328==    by 0x6874C1F: ???
==22328==    by 0x68A4C5D: ???
==22328==    by 0x5366AD4: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22328==    by 0x536785B: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22328==    by 0x5367E8B: p11_kit_initialize_registered (in /usr/lib/libp11-kit.so.0.0.0)
==22328==    by 0x4E76CCD: gnutls_pkcs11_init (pkcs11.c:448)
==22328== 
FAIL: srn1
Self test `./srn2' finished with 0 errors
==22343== 4 bytes in 1 blocks are definitely lost in loss record 2 of 33
==22343==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22343==    by 0x55EF881: strdup (strdup.c:43)
==22343==    by 0x536717B: p11_kit_registered_module_to_name (in /usr/lib/libp11-kit.so.0.0.0)
==22343==    by 0x4E76D04: gnutls_pkcs11_init (pkcs11.c:462)
==22343==    by 0x4E5D23A: gnutls_global_init (gnutls_global.c:252)
==22343==    by 0x4012CC: doit (srn2.c:99)
==22343==    by 0x401B54: main (utils.c:149)
==22343== 
==22343== 252,824 (8,232 direct, 244,592 indirect) bytes in 1 blocks are definitely lost in loss record 33 of 33
==22343==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22343==    by 0x68BA49B: ???
==22343==    by 0x68BC248: ???
==22343==    by 0x68BC483: ???
==22343==    by 0x68B9FE4: ???
==22343==    by 0x685D550: ???
==22343==    by 0x6874C1F: ???
==22343==    by 0x68A4C5D: ???
==22343==    by 0x5366AD4: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22343==    by 0x536785B: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22343==    by 0x5367E8B: p11_kit_initialize_registered (in /usr/lib/libp11-kit.so.0.0.0)
==22343==    by 0x4E76CCD: gnutls_pkcs11_init (pkcs11.c:448)
==22343== 
FAIL: srn2
Self test `./srn3' finished with 0 errors
==22358== 4 bytes in 1 blocks are definitely lost in loss record 2 of 33
==22358==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22358==    by 0x55EF881: strdup (strdup.c:43)
==22358==    by 0x536717B: p11_kit_registered_module_to_name (in /usr/lib/libp11-kit.so.0.0.0)
==22358==    by 0x4E76D04: gnutls_pkcs11_init (pkcs11.c:462)
==22358==    by 0x4E5D23A: gnutls_global_init (gnutls_global.c:252)
==22358==    by 0x40121A: doit (srn3.c:101)
==22358==    by 0x4016E4: main (utils.c:149)
==22358== 
==22358== 252,824 (8,232 direct, 244,592 indirect) bytes in 1 blocks are definitely lost in loss record 33 of 33
==22358==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22358==    by 0x68BA49B: ???
==22358==    by 0x68BC248: ???
==22358==    by 0x68BC483: ???
==22358==    by 0x68B9FE4: ???
==22358==    by 0x685D550: ???
==22358==    by 0x6874C1F: ???
==22358==    by 0x68A4C5D: ???
==22358==    by 0x5366AD4: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22358==    by 0x536785B: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22358==    by 0x5367E8B: p11_kit_initialize_registered (in /usr/lib/libp11-kit.so.0.0.0)
==22358==    by 0x4E76CCD: gnutls_pkcs11_init (pkcs11.c:448)
==22358== 
FAIL: srn3
Self test `./srn4' finished with 0 errors
==22373== 4 bytes in 1 blocks are definitely lost in loss record 2 of 33
==22373==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22373==    by 0x55EF881: strdup (strdup.c:43)
==22373==    by 0x536717B: p11_kit_registered_module_to_name (in /usr/lib/libp11-kit.so.0.0.0)
==22373==    by 0x4E76D04: gnutls_pkcs11_init (pkcs11.c:462)
==22373==    by 0x4E5D23A: gnutls_global_init (gnutls_global.c:252)
==22373==    by 0x4012CA: doit (srn4.c:101)
==22373==    by 0x4018F4: main (utils.c:149)
==22373== 
==22373== 252,824 (8,232 direct, 244,592 indirect) bytes in 1 blocks are definitely lost in loss record 33 of 33
==22373==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22373==    by 0x68BA49B: ???
==22373==    by 0x68BC248: ???
==22373==    by 0x68BC483: ???
==22373==    by 0x68B9FE4: ???
==22373==    by 0x685D550: ???
==22373==    by 0x6874C1F: ???
==22373==    by 0x68A4C5D: ???
==22373==    by 0x5366AD4: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22373==    by 0x536785B: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22373==    by 0x5367E8B: p11_kit_initialize_registered (in /usr/lib/libp11-kit.so.0.0.0)
==22373==    by 0x4E76CCD: gnutls_pkcs11_init (pkcs11.c:448)
==22373== 
FAIL: srn4
Self test `./srn5' finished with 0 errors
==22388== 4 bytes in 1 blocks are definitely lost in loss record 2 of 33
==22388==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22388==    by 0x55EF881: strdup (strdup.c:43)
==22388==    by 0x536717B: p11_kit_registered_module_to_name (in /usr/lib/libp11-kit.so.0.0.0)
==22388==    by 0x4E76D04: gnutls_pkcs11_init (pkcs11.c:462)
==22388==    by 0x4E5D23A: gnutls_global_init (gnutls_global.c:252)
==22388==    by 0x4012CA: doit (srn5.c:102)
==22388==    by 0x4018E4: main (utils.c:149)
==22388== 
==22388== 252,824 (8,232 direct, 244,592 indirect) bytes in 1 blocks are definitely lost in loss record 33 of 33
==22388==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22388==    by 0x68BA49B: ???
==22388==    by 0x68BC248: ???
==22388==    by 0x68BC483: ???
==22388==    by 0x68B9FE4: ???
==22388==    by 0x685D550: ???
==22388==    by 0x6874C1F: ???
==22388==    by 0x68A4C5D: ???
==22388==    by 0x5366AD4: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22388==    by 0x536785B: ??? (in /usr/lib/libp11-kit.so.0.0.0)
==22388==    by 0x5367E8B: p11_kit_initialize_registered (in /usr/lib/libp11-kit.so.0.0.0)
==22388==    by 0x4E76CCD: gnutls_pkcs11_init (pkcs11.c:448)
==22388== 
FAIL: srn5
===================================
6 of 6 tests failed
Please report to bug-gnutls at gnu.org
===================================
make[4]: *** [check-TESTS] Error 1
make[4]: Leaving directory `/home/geg/tmp/gnutls26-2.12.20/tests/safe-renegotiation'
make[3]: *** [check-am] Error 2
make[3]: Leaving directory `/home/geg/tmp/gnutls26-2.12.20/tests/safe-renegotiation'
make[2]: *** [check-recursive] Error 1
make[2]: Leaving directory `/home/geg/tmp/gnutls26-2.12.20/tests'
make[1]: *** [check-recursive] Fehler 1
make[1]: Leaving directory `/home/geg/tmp/gnutls26-2.12.20'
make: *** [debian/stamp-makefile-check] Fehler 2


Regards

Sven

P.S.: I am running p11-kit 0.13 from debian

-- 
"Those who do not understand Unix are condemned to reinvent it, poorly"
(Henry Spencer)

/me is giggls at ircnet, http://sven.gegg.us/ on the Web




More information about the Gnutls-devel mailing list