Merge pull request #17879 from frederic34/patch-7

try to fix
This commit is contained in:
Laurent Destailleur 2021-06-11 18:02:29 +02:00 committed by GitHub
commit fbe970c739
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8009,7 +8009,7 @@ function dol_eval($s, $returnvalue = 0, $hideerrors = 1)
$forbiddenphpstrings = array_merge($forbiddenphpstrings, array("fopen(", "file_put_contents(", "fputs(", "fputscsv(", "fwrite(", "fpassthru(", "unlink(", "mkdir(", "rmdir(", "symlink(", "touch(", "umask("));
$forbiddenphpstrings = array_merge($forbiddenphpstrings, array('function(', '$$', 'call_user_func('));
$forbiddenphpstrings = array_merge($forbiddenphpstrings, array('_ENV', '_SESSION', '_COOKIE', '_GET', '_POST', '_REQUEST'));
$forbiddenphpregex = array('global\s+\$');
$forbiddenphpregex = 'global\s+\$';
do {
$oldstringtoclean = $s;
$s = str_ireplace($forbiddenphpstrings, '__forbiddenstring__', $s);