gnutls 3.1.0 -> 3.1.4 wMNAF-based multiplication change and a problem

Arkadiusz Miśkiewicz arekm at maven.pl
Fri Nov 23 23:52:49 CET 2012


Hi

Starting with a commit:

commit 45bf20ad3f799bf219958c3ba705898440c74e4a
Author: Ilya Tumaykin <itumaykin at gmail.com>
Date:   Thu Aug 30 11:36:34 2012 +0400

    wMNAF-based multiplication

php started to segfault here.

To reproduce here I'm using php cli program + module gmp and curl.

Uninstalling php gmp module and the problem is gone. My curl uses gnutls.

The fact that I need gmp php module to reproduce makes me wonder
if there is some global state (maybe in gmp) that's overwritten by gnutls?

Any ideas/hints on what can be going on here?

Thanks,

ps. to reproduce, php + curl php module + gmp php module. Run php cli and press ctrl+d.

Program received signal SIGSEGV, Segmentation fault.
0x00007fffea23ef20 in ?? ()
(gdb) bt
#0  0x00007fffea23ef20 in ?? ()
#1  0x00007fffeb445d3b in mp_clear_multi (a=a at entry=0xc63ed0) at multi.c:38
#2  0x00007fffeb4472ca in ecc_del_point (p=0xc63ed0) at ecc_points.c:62
#3  0x00007fffeb446972 in _ecc_wmnaf_cache_entry_free (p=<optimized out>) at ecc_mulmod_cached.c:54
#4  ecc_wmnaf_cache_free () at ecc_mulmod_cached.c:68
#5  0x00007fffeb445685 in gnutls_crypto_deinit () at init.c:44
#6  0x00007fffeb3adb71 in gnutls_global_deinit () at gnutls_global.c:305
#7  0x00007fffee0c9a79 in Curl_gtls_cleanup () at gtls.c:182
#8  0x00007fffee0ca189 in Curl_ssl_cleanup () at sslgen.c:193
#9  0x00007fffee0bbbf5 in curl_global_cleanup () at easy.c:325
#10 0x00007fffee6f9bf8 in zm_shutdown_curl () from /usr/lib64/php/curl.so
#11 0x00007ffff7a96105 in module_destructor () from /usr/lib64/libphp_common-5.3.18.so
#12 0x00007ffff7a9b4ae in ?? () from /usr/lib64/libphp_common-5.3.18.so
#13 0x00007ffff7a9cd08 in zend_hash_graceful_reverse_destroy () from /usr/lib64/libphp_common-5.3.18.so
#14 0x00007ffff7a8f175 in zend_shutdown () from /usr/lib64/libphp_common-5.3.18.so
#15 0x00007ffff7a3e01b in php_module_shutdown () from /usr/lib64/libphp_common-5.3.18.so
#16 0x0000000000403406 in main ()
(gdb)

-- 
Arkadiusz Miśkiewicz, arekm / maven.pl




More information about the Gnutls-help mailing list