closed security hole of using evaled code to show globals vars (which contain eg. passwords)

This commit is contained in:
Ralf Becker 2002-05-13 14:46:47 +00:00
parent 77374edc32
commit 424e3ac8b2

View File

@ -329,7 +329,8 @@
} }
if($val[0] == '@') if($val[0] == '@')
{ {
$val = 'return '.substr($val,1).';'; // removing the $ to close security hole of showing vars, which contain eg. passwords
$val = 'return '.substr(str_replace('$','',$val),1).';';
// echo "<p>eval('$val')="; // echo "<p>eval('$val')=";
$val = eval($val); $val = eval($val);
// echo "'$val'</p>"; // echo "'$val'</p>";