From e1c8b46a9d64fa668a97263cb4af66661aafc3c4 Mon Sep 17 00:00:00 2001 From: skodak Date: Wed, 20 Apr 2005 20:45:43 +0000 Subject: [PATCH] more cleaning of url parameter in redirect() - SC#100 --- lib/weblib.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/weblib.php b/lib/weblib.php index 6726182d666..e4701ba1e83 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -3687,6 +3687,7 @@ function redirect($url, $message='', $delay='0') { $message = clean_text($message); $url = html_entity_decode($url); // for php < 4.3.0 this is defined in moodlelib.php + $url = str_replace(array("\n", "\r"), '', $url); // some more cleaning $encodedurl = htmlentities($url); if (empty($message)) {