|   | php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
| 
  [2017-07-04 21:44 UTC] tessarek at evermeet dot cx
 Description:
------------
Calling db2_pconnect a few times results in a signal 11 (SIGSEGV).
The backtrace reveals that the segfault occurs on this line:
2486:  rc = SQLGetConnectAttr(conn_res->hdbc, SQL_ATTR_PING_DB, (SQLPOINTER)&conn_alive, 0, NULL);
Here's the entire backtrace:
#0  0x000000000072beb8 in _php_db2_connect_helper (execute_data=0x7f1eeca14150, return_value=0x7f1eeca14110, pconn_res=0x7fff4003b570, isPersistent=1)
    at /ext/php-7.1.6-debug/ext/ibm_db2/ibm_db2.c:2486
#1  0x000000000072c684 in _php_db2_pconnect (execute_data=0x7f1eeca14150, return_value=0x7f1eeca14110, isPersistent=1) at /ext/php-7.1.6-debug/ext/ibm_db2/ibm_db2.c:2903
#2  0x000000000072c7df in zif_db2_pconnect (execute_data=0x7f1eeca14150, return_value=0x7f1eeca14110) at /ext/php-7.1.6-debug/ext/ibm_db2/ibm_db2.c:2977
#3  0x0000000000b43f49 in ZEND_DO_ICALL_SPEC_RETVAL_USED_HANDLER () at /ext/php-7.1.6-debug/Zend/zend_vm_execute.h:675
#4  0x0000000000b4366c in execute_ex (ex=0x7f1eeca14030) at /ext/php-7.1.6-debug/Zend/zend_vm_execute.h:429
#5  0x0000000000b4377e in zend_execute (op_array=0x7f1eeca6b000, return_value=0x0) at /ext/php-7.1.6-debug/Zend/zend_vm_execute.h:474
#6  0x0000000000ae4dfb in zend_execute_scripts (type=8, retval=0x0, file_count=3) at /ext/php-7.1.6-debug/Zend/zend.c:1476
#7  0x0000000000a54a02 in php_execute_script (primary_file=0x7fff4003dbb0) at /ext/php-7.1.6-debug/main/main.c:2537
#8  0x0000000000bd3663 in main (argc=4, argv=0x7fff4003ddd8) at /ext/php-7.1.6-debug/sapi/fpm/fpm/fpm_main.c:1966
PatchesPatch_new (last revision 2017-08-17 07:14 UTC by vnkbabu@php.net)fix_pconnect (last revision 2017-08-16 11:06 UTC by vnkbabu@php.net) Pull RequestsHistoryAllCommentsChangesGit/SVN commits             | |||||||||||||||||||||||||||
|  Copyright © 2001-2025 The PHP Group All rights reserved. | Last updated: Fri Oct 31 08:00:01 2025 UTC | 
Hi Helmut, I have received your concern regarding the possible security issue in db2_pconnect, i agree with you and asked abhinav to use only database and user id. Also i informed my developer abhinav radke to contact you regarding this defect. He will be contacting you through the e-mail, please help him with more information about the issue.