From 037af6890fe6fdb84a08d3c86083e847c90ec0ad Mon Sep 17 00:00:00 2001
From: Aleksander Machniak <alec@alec.pl>
Date: Tue, 22 Oct 2013 08:17:26 -0400
Subject: [PATCH] Fix vulnerability in handling _session argument of utils/save-prefs (#1489382)

---
 program/steps/settings/folders.inc |    9 ++-------
 1 files changed, 2 insertions(+), 7 deletions(-)

diff --git a/program/steps/settings/folders.inc b/program/steps/settings/folders.inc
index 12e449e..778d93c 100644
--- a/program/steps/settings/folders.inc
+++ b/program/steps/settings/folders.inc
@@ -349,7 +349,7 @@
             array('value' => $folder_utf8, 'disabled' => $disabled ? 'disabled' : '')));
 
         $a_js_folders['rcmrow'.$idx] = array($folder_utf8,
-            Q($display_folder), $protected || $folder['virtual']);
+            $display_folder, $protected || $folder['virtual']);
     }
 
     $RCMAIL->plugins->exec_hook('folders_list', array('table' => $table));
@@ -369,12 +369,7 @@
     if (!$attrib['id'])
         $attrib['id'] = 'rcmfolderframe';
 
-    $attrib['name'] = $attrib['id'];
-
-    $OUTPUT->set_env('contentframe', $attrib['name']);
-    $OUTPUT->set_env('blankpage', $attrib['src'] ? $OUTPUT->abs_url($attrib['src']) : 'program/resources/blank.gif');
-
-    return html::iframe($attrib);
+    return $OUTPUT->frame($attrib, true);
 }
 
 function rcmail_rename_folder($oldname, $newname)

--
Gitblit v1.9.1