Enhance the WAF
This commit is contained in:
parent
d1fa46089f
commit
6f01869bcb
@ -752,7 +752,8 @@ function checkVal($out = '', $check = 'alphanohtml', $filter = null, $options =
|
|||||||
$out = trim($out);
|
$out = trim($out);
|
||||||
do {
|
do {
|
||||||
$oldstringtoclean = $out;
|
$oldstringtoclean = $out;
|
||||||
$out = str_ireplace(array('"', '"', '../'), '', $out);
|
// Note &, '&', '&'... is a simple char like '&' alone but there is no reason to accept such way to encode input data.
|
||||||
|
$out = str_ireplace(array('&', '&', '&', '"', '"', '"', '"', '"', '/', '/', '/', '../'), '', $out);
|
||||||
} while ($oldstringtoclean != $out);
|
} while ($oldstringtoclean != $out);
|
||||||
// keep lines feed
|
// keep lines feed
|
||||||
}
|
}
|
||||||
@ -765,7 +766,8 @@ function checkVal($out = '', $check = 'alphanohtml', $filter = null, $options =
|
|||||||
$out = trim($out);
|
$out = trim($out);
|
||||||
do {
|
do {
|
||||||
$oldstringtoclean = $out;
|
$oldstringtoclean = $out;
|
||||||
$out = str_ireplace(array('"', '"', '../'), '', $out);
|
// Note &, '&', '&'... is a simple char like '&' alone but there is no reason to accept such way to encode input data.
|
||||||
|
$out = str_ireplace(array('&', '&', '&', '"', '"', '"', '"', '"', '/', '/', '/', '../'), '', $out);
|
||||||
} while ($oldstringtoclean != $out);
|
} while ($oldstringtoclean != $out);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user