Bug #80588 [Com]: opcache causes include() to include an utterly random unrelated file
| From: | hfdifguojoweeui322 at gmail dot com | Date: | Fri, 09 Jun 2023 09:05:40 +0000 |
| Subject: | Bug #80588 [Com]: opcache causes include() to include an utterly random unrelated file | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-244638@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=80588&edit=1
ID: 80588
Comment by: hfdifguojoweeui322 at gmail dot com
Reported by: php4fan at gmail dot com
Summary: opcache causes include() to include an utterly
random unrelated file
Status: Open
Type: Bug
Package: opcache
Operating System: linux debian 9
PHP Version: 7.4.13
Block user comment: N
Private report: N
New Comment:
That was so amazing article I loved that.
More info : - (https://www.ballsportsgear.com/pickleball-serving-tips/)github.com
Previous Comments:
------------------------------------------------------------------------
[2021-02-23 11:56:38] nikic@php.net
It's unlikely this can be addressed without a way to reproduce this issue.
------------------------------------------------------------------------
[2021-02-23 11:47:15] php4fan at gmail dot com
Why is this being ignored? The impact of this is devastating.
------------------------------------------------------------------------
[2021-01-04 18:44:33] php4fan at gmail dot com
Description:
------------
In my code I have the following code executed many times:
<?php
eval("
include("/path/to/a/file_1.php");
");
?>
It is not as direct as that: the evaled string is fetched from a db rather than being a literal, but
it's fixed as the above.
Under some apparently random circumstances, at the Nth time that gets executed, it executes a
completely unrelated file /path/to/another/file_2.php instead of the one whose name is being passed
to include().
Disabling opcache fixes the issue.
I haven't been able to recreate a minimal, sharable, reproducible test case. With my code it
happens systematically 100% of the time that this given script is executed.
It looks almost as if, because of a hash collision or something of that sort (uttelry random but at
the same time 100% reproducible), the opcache ended up fetching a completely unrelated precompiled
piece of bytecode.
This is a REGRESSION, it happens with PHP 7.4.11 but not with PHP 5.6
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=80588&edit=1