-
-
Save lisachenko/00fa92f811511f347e3a to your computer and use it in GitHub Desktop.
Bug with Optimizer+
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class BugLoader extends php_user_filter | |
{ | |
public function filter($in, $out, &$consumed, $closing) | |
{ | |
eval("class Test extends ArrayObject {}"); | |
return PSFS_PASS_ON; | |
} | |
} | |
function dynamicInclude() | |
{ | |
return "php://filter/read=bug.test/resource=test.php"; | |
} | |
echo "ArrayObject class ", class_exists('ArrayObject') ? 'exists' : 'not found'; | |
stream_filter_register('bug.test', 'BugLoader'); | |
include dynamicInclude(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Fatal error: Class 'ArrayObject' not found in C:\Work\go\demos\bug.php(31) : eval()'d code on line 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// empty file here |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment