php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #68413 disable_functions will cause opcache function_exists fault
Submitted: 2014-11-13 09:38 UTC Modified: 2014-11-14 04:45 UTC
From: 26403799 at qq dot com Assigned: laruence (profile)
Status: Closed Package: opcache
PHP Version: 5.6.2 OS: CentOS 6.6
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: 26403799 at qq dot com
New email:
PHP Version: OS:

 

 [2014-11-13 09:38 UTC] 26403799 at qq dot com
Description:
------------
if php.ini set:
disable_functions = exec, 
and enable opcache

php-cgi run:
<?php
function_exists('exec');
?>

will output: Segmentation fault (core dumped)

but this is OK:
<?php
function_exists('exec111111');
?>

Test script:
---------------
<?php
// if php.ini set  disable_functions = exec, and enable opcache
// will output: Segmentation fault (core dumped)
function_exists('exec');

echo "test1";
?>

Expected result:
----------------
test1

Actual result:
--------------
error output:
Segmentation fault (core dumped)

dmesg:
php-cgi[30749]: segfault at 8c ip 00007f255e03c360 sp 00007ffff85b6610 error 4 in opcache.so[7f255e020000+22000]
php-cgi[30839]: segfault at 8c ip 00007f971496a360 sp 00007fff1318ca90 error 4 in opcache.so[7f971494e000+22000]
php-cgi[30959]: segfault at 8c ip 00007f0169148360 sp 00007fff8904ad30 error 4 in opcache.so[7f016912c000+22000]
php-cgi[31106]: segfault at 8c ip 00007f86644e5360 sp 00007fff1a5142a0 error 4 in opcache.so[7f86644c9000+22000]
php-cgi[31162]: segfault at 8c ip 00007eff90f7c360 sp 00007fff03e3eca0 error 4 in opcache.so[7eff90f60000+22000]
php-cgi[31341]: segfault at 8c ip 00007fc47c1e7360 sp 00007ffffb720a00 error 4 in opcache.so[7fc47c1cb000+22000]


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2014-11-13 10:35 UTC] laruence@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: laruence
 [2014-11-13 10:35 UTC] laruence@php.net
The fix for this bug has been committed.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.

this must be fixed already... but hasn't released.
 [2014-11-14 02:22 UTC] 26403799 at qq dot com
laruence@php.net:
I install php5.6.3 ,but still not solve this problem.
and i can not open the website: http://snaps.php.net/

# /opt/app4www/php5.6/bin/php-cgi -v
PHP 5.6.3 (cgi-fcgi) (built: Nov 14 2014 09:57:25)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2014 Zend Technologies
    with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2014, by Zend Technologies
# /opt/app4www/php5.6/bin/php-cgi /2.php
Segmentation fault (core dumped)
 [2014-11-14 04:45 UTC] rasmus@php.net
It is not in 5.6.3. It will be in the next release. Grab the sources and compile it if you need it quicker.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 18:02:40 2024 UTC