#48081 [Fbk->Bgs]: stream_socket_client with SSL causes SEGFAULT
| From: | pajoye@php.net | Date: | Sun, 26 Apr 2009 20:40:40 +0000 |
| Subject: | #48081 [Fbk->Bgs]: stream_socket_client with SSL causes SEGFAULT | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-136340@lists.php.net to get a copy of this message | ||
ID: 48081
Updated by: pajoye@php.net
Reported By: alexander at wright-family dot me dot uk
-Status: Feedback
+Status: Bogus
Bug Type: Reproducible crash
Operating System: Gentoo Linux
PHP Version: 5.2.9
Assigned To: pajoye
New Comment:
missed the last comment, no php bug then > bogus.
Previous Comments:
------------------------------------------------------------------------
[2009-04-26 20:39:32] pajoye@php.net
Which openssl version do you use?
Can you try to compile PHP yourself and see if you can reproduce this
problem?
------------------------------------------------------------------------
[2009-04-26 20:02:44] alexander at wright-family dot me dot uk
Further information:
Buggy PHP compiled with x86_64-pc-linux-gnu-3.4.6
I compiled the same version of PHP on another AMD64 machine with
x86_64-pc-linux-gnu-4.2.4 and this works correctly (with suhosin
enabled).
------------------------------------------------------------------------
[2009-04-26 19:09:15] alexander at wright-family dot me dot uk
Also available here:
http://www.wright-family.me.uk/shared/phpgdb.txt
------------------------------------------------------------------------
[2009-04-26 19:06:07] alexander at wright-family dot me dot uk
Suhosin removed. Is this enough debug info?
Cheers.
(gdb) bt
#0 0xffffffffff70085e in ?? ()
#1 0x00006ad6211f47f2 in gettimeofday ()
#2 0x00006ad619e3e2ba in gettimeofday () from /lib/libc.so.6
#3 0x00000000004934ff in php_openssl_enable_crypto (stream=0x12ce7e8,
sslsock=0x12ce730, cparam=0x740fac178940, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/ext/openssl/xp_ssl.c:417
#4 0x0000000000492ddf in php_openssl_sockop_set_option
(stream=0x12ce7e8, option=8, value=0, ptrparam=0x740fac178940,
tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/ext/openssl/xp_ssl.c:669
#5 0x00000000008346e0 in _php_stream_set_option (stream=0x12ce7e8,
option=8, value=0, ptrparam=0x740fac178940, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/main/streams/streams.c:1155
#6 0x00000000008464cf in php_stream_xport_crypto_enable
(stream=0x12ce7e8, activate=1, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/main/streams/transports.c:371
#7 0x0000000000492e9b in php_openssl_sockop_set_option
(stream=0x12ce7e8, option=7, value=0, ptrparam=0x740fac178b00,
tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/ext/openssl/xp_ssl.c:689
#8 0x00000000008346e0 in _php_stream_set_option (stream=0x12ce7e8,
option=7, value=0, ptrparam=0x740fac178b00, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/main/streams/streams.c:1155
#9 0x0000000000845f28 in php_stream_xport_connect (stream=0x12ce7e8,
name=0x12cd8ce "www.google.com:443", namelen=18, asynchronous=0,
timeout=0x740fac178e60, error_text=0x740fac178d08,
error_code=0x740fac178e4c, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/main/streams/transports.c:230
#10 0x0000000000845a39 in _php_stream_xport_create (name=0x12cd8ce
"www.google.com:443", namelen=18, options=12, flags=2,
persistent_id=0x0,
timeout=0x740fac178e60, context=0x12c2d20,
error_string=0x740fac178e38, error_code=0x740fac178e4c,
__php_stream_call_depth=0,
__zend_filename=0xc04480
"/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/ext/standard/streamsfuncs.c",
__zend_lineno=129,
__zend_orig_filename=0x0, __zend_orig_lineno=0, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/main/streams/transports.c:143
#11 0x00000000007d21a6 in zif_stream_socket_client (ht=6,
return_value=0x12cda30, return_value_ptr=0x0, this_ptr=0x0,
return_value_used=1,
tsrm_ls=0xfad400) at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/ext/standard/streamsfuncs.c:126
#12 0x00000000008c285d in execute_internal
(execute_data_ptr=0x740fac179460, return_value_used=1,
tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/Zend/zend_execute.c:1373
#13 0x00006ad61978a5dd in ?? () from
/usr/lib64/php5/lib/php/extensions/debug-zts-20060613/suhosin.so
#14 0x00000000008c337f in zend_do_fcall_common_helper_SPEC
(execute_data=0x740fac179460, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/Zend/zend_vm_execute.h:202
#15 0x00000000008cb2fa in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0x740fac179460, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/Zend/zend_vm_execute.h:1729
#16 0x00000000008c2c98 in execute (op_array=0x12cb8c0,
tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/Zend/zend_vm_execute.h:92
#17 0x00006ad6197876eb in ?? () from
/usr/lib64/php5/lib/php/extensions/debug-zts-20060613/suhosin.so
#18 0x00006ad619787785 in ?? () from
/usr/lib64/php5/lib/php/extensions/debug-zts-20060613/suhosin.so
#19 0x000000000088ffcc in zend_execute_scripts (type=8,
tsrm_ls=0xfad400, retval=0x0, file_count=3)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/Zend/zend.c:1134
#20 0x00000000008126c7 in php_execute_script
(primary_file=0x740fac17bc00, tsrm_ls=0xfad400)
at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/main/main.c:2023
#21 0x000000000093e561 in main (argc=2, argv=0x740fac17bec8) at
/var/tmp/portage/dev-lang/php-5.2.9-r2/work/php-5.2.9/sapi/cli/php_cli.c:1133
(gdb)
------------------------------------------------------------------------
[2009-04-26 18:28:02] scottmac@php.net
Can you remove sushosin and get debug symbols for the rest of the php
binary.
I can't reproduce this on 5.2.10-dev or 5.3.0-dev
Output is:
Warning: stream_socket_client(): unable to connect to
ssl://www.google.com:443 (Operation now in progress) in
/private/tmp/test.php on line 7
Error:36: Operation now in progress
Headers:
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/48081
--
Edit this bug report at http://bugs.php.net/?id=48081&edit=1