From 44f9f2f8b7475c2d48c529d9bfd0ff473cd328b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Mon, 22 Sep 2008 10:13:32 +0000 Subject: [PATCH] XSS in MSIE using NUL byte, thanks to JPCERT. --- ChangeLog | 3 +++ libraries/js_escape.lib.php | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/ChangeLog b/ChangeLog index 7e8f8e778..7ded09279 100644 --- a/ChangeLog +++ b/ChangeLog @@ -11,6 +11,9 @@ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyA - [core] do not automatically set and create TempDir, it might lead to security issue (thanks to Thijs Kinkhorst) +2.11.9.2 (2008-09-22) +- [security] XSS in MSIE using NUL byte, thanks to JPCERT. + 2.11.9.1 (2008-09-15) - [security] Code execution vulnerability, thanks to Norman Hippert diff --git a/libraries/js_escape.lib.php b/libraries/js_escape.lib.php index 9d128aa31..d4dfb5604 100644 --- a/libraries/js_escape.lib.php +++ b/libraries/js_escape.lib.php @@ -46,6 +46,10 @@ function PMA_jsFormat($a_string = '', $add_backquotes = true) * enclosed by * this requires only to escape ' with \' and end of script block * + * We also remove NUL byte as some browsers (namely MSIE) ignore it and + * it and inserting it anywhere inside '', '\\' => '\\\\', '\'' => '\\\'', "\n" => '\n',