From 715c88b52eb1ddd7cfd367c610dc430c5639f63d Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Tue, 26 Apr 2011 20:22:29 +0000 Subject: [PATCH] Fix: A local file inclusion vulnerability can be exploited to include arbitrary files. --- htdocs/main.inc.php | 5 +++-- htdocs/user/passwordforgotten.php | 27 ++++++++++++++------------- 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 733de089a67..113c22b8b22 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -75,6 +75,7 @@ function test_sql_and_script_inject($val,$get) $sql_inj += preg_match('/insert[\s]+into/i', $val); $sql_inj += preg_match('/select.+from/i', $val); $sql_inj += preg_match('/union.+select/i', $val); + $sql_inj += preg_match('/(\.\.%2f)+/i', $val); // For XSS Injection done by adding javascript with script $sql_inj += preg_match('/