Bug #76267 [Fbk]: pg_escape_string, pg_send_query will cause a segfault in some rare cases
| From: | yohgaki@php.net | Date: | Thu, 26 Apr 2018 00:50:14 +0000 |
| Subject: | Bug #76267 [Fbk]: pg_escape_string, pg_send_query will cause a segfault in some rare cases | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-214900@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=76267&edit=1
ID: 76267
Updated by: yohgaki@php.net
Reported by: nick dot ilyin at oracle dot com
Summary: pg_escape_string, pg_send_query will cause a
segfault in some rare cases
Status: Feedback
Type: Bug
Package: PDO PgSQL
Operating System: Ubuntu 16.04.4 LTS
PHP Version: 7.1.16
Block user comment: N
Private report: N
New Comment:
pg_escape_string() is simple libpq wrapper function, so chances are high that other feature's
memory management error is the cause. Please do not forget to paste list of installed modules. i.e.
php -m or phpinfo()'s modules list.
Previous Comments:
------------------------------------------------------------------------
[2018-04-26 00:34:07] requinix@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php
for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php
for Win32
Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.
------------------------------------------------------------------------
[2018-04-25 14:34:10] nick dot ilyin at oracle dot com
Description:
------------
In some rare cases both pg_escape_string and pg_send_query cause a segfault in Apache/2.4.18.
Unfortunately it happens in cases where I cannot replicate outside of our stack with a test script.
However, I have a test machine up where I can replicate the issue consistently so I can provide
whatever information is necessary from there.
I can provide whatever output is needed.
Test script:
---------------
Unable to provide given the nature of not knowing how to reproduce the issue in a simple test
script. This issue is fully reproducible in a brand new machine built on our stack and is
reproducible on brand new Ubuntu 16.04.4 machines using PHP 7.1.16.
Expected result:
----------------
No segmentation fault.
Actual result:
--------------
In the error log: [Wed Apr 25 10:32:28.271689 2018] [core:notice] [pid 32568] AH00052: child pid
12510 exit signal Segmentation fault (11)
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=76267&edit=1