Reduce possible actions
This commit is contained in:
parent
ff2f93815f
commit
7755a44958
@ -1908,7 +1908,7 @@ if (($action == 'updatesource' || $action == 'updatecontent' || $action == 'conf
|
||||
// Security analysis
|
||||
$phpfullcodestring = dolKeepOnlyPhpCode($objectpage->content);
|
||||
//print dol_escape_htmltag($phpfullcodestring);exit;
|
||||
$forbiddenphpcommands = array("exec", "passthru", "system", "shell_exec", "proc_open");
|
||||
$forbiddenphpcommands = array("exec", "passthru", "system", "shell_exec", "proc_open", "eval", "dol_eval");
|
||||
if (empty($conf->global->WEBSITE_PHP_ALLOW_WRITE)) { // If option is not on, we disallow functions to write files
|
||||
$forbiddenphpcommands = array_merge($forbiddenphpcommands, array("fopen", "file_put_contents", "fputs", "fputscsv", "fwrite", "fpassthru", "unlink", "mkdir", "rmdir", "symlink", "touch", "umask"));
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user