php (ssl?) global lock again

Elan Ruusamäe glen at pld-linux.org
Sat Oct 28 15:36:52 CEST 2017


On 27.10.2017 19:09, Elan Ruusamäe wrote:
> php -m crashes again, if either of the modules is installed together:
>
> # rpm -qf /etc/php71/conf.d/curl.ini /etc/php71/conf.d/mongodb.ini
> php71-curl-7.1.9-1.x86_64
> php71-pecl-mongodb-1.2.11-1.x86_64
>
>
> [root at blodnatt ~]# rpm -q curl
> curl-7.55.1-1.x86_64
>
> some openssl global lock again?

created reproducer. curl, openssl, mongodb are needed (at least) for 
reproducer:

https://gitlab.com/glensc/php71-mongodb-crash

docker run --rm -it registry.gitlab.com/glensc/php71-mongodb-crash:1 gdb 
--ex 'set pagination off' --ex run --ex bt --args php71 -m

GNU gdb (GDB) 8.0-1 (PLD Linux)
...

Starting program: /usr/bin/php71 -m
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[PHP Modules]
Core
curl
date
json
libxml
mongodb
openssl
pcre
Reflection
SimpleXML
SPL
standard

[Zend Modules]


Program received signal SIGSEGV, Segmentation fault.
0x00007ffff07d4830 in ?? ()
#0  0x00007ffff07d4830 in ?? ()
#1  0x00007ffff33725e2 in CRYPTO_THREADID_current (id=0x7fffffffe7b0) at 
cryptlib.c:493
#2  0x00007ffff34316b8 in ERR_remove_thread_state (id=id at entry=0x0) at 
err.c:1001
#3  0x00007ffff4b72eaa in Curl_ossl_cleanup () at vtls/openssl.c:797
#4  0x00007ffff4b73d99 in Curl_ssl_cleanup () at vtls/vtls.c:173
#5  0x00007ffff4b43c45 in curl_global_cleanup () at easy.c:323
#6  0x00007ffff4d9a818 in zm_shutdown_curl (type=<optimized out>, 
module_number=8) at /usr/src/debug/php-7.1.9/ext/curl/interface.c:1408
#7  0x00007ffff7a1ebe7 in module_destructor 
(module=module at entry=0x6599c0) at 
/usr/src/debug/php-7.1.9/Zend/zend_API.c:2501
#8  0x00007ffff7a173bc in module_destructor_zval (zv=<optimized out>) at 
/usr/src/debug/php-7.1.9/Zend/zend.c:633
#9  0x00007ffff7a2a418 in _zend_hash_del_el_ex (prev=<optimized out>, 
p=<optimized out>, idx=<optimized out>, ht=<optimized out>) at 
/usr/src/debug/php-7.1.9/Zend/zend_hash.c:997
#10 _zend_hash_del_el (p=0x627e60, idx=7, ht=0x7ffff7dd5620 
<module_registry>) at /usr/src/debug/php-7.1.9/Zend/zend_hash.c:1020
#11 zend_hash_graceful_reverse_destroy (ht=ht at entry=0x7ffff7dd5620 
<module_registry>) at /usr/src/debug/php-7.1.9/Zend/zend_hash.c:1476
#12 0x00007ffff7a1cfbc in zend_destroy_modules () at 
/usr/src/debug/php-7.1.9/Zend/zend_API.c:1978
#13 0x00007ffff7a17ea1 in zend_shutdown () at 
/usr/src/debug/php-7.1.9/Zend/zend.c:876
#14 0x00007ffff79b4dab in php_module_shutdown () at 
/usr/src/debug/php-7.1.9/main/main.c:2420
#15 0x0000000000404d3f in main (argc=2, argv=0x61e1c0) at 
/usr/src/debug/php-7.1.9/sapi/cli/php_cli.c:1396
(gdb)



-- 
glen



More information about the pld-devel-en mailing list