浏览代码

Fix to prevent query containing username and password from being displayed if imap connection fails during login. Similar code committed to stable as well.

tassium 22 年之前
父节点
当前提交
f4265d8463
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      functions/imap_general.php

+ 4 - 1
functions/imap_general.php

@@ -302,7 +302,10 @@ function sqimap_error_box($title, $query = '', $message_title = '', $message = '
     set_up_language($squirrelmail_language);
     require_once(SM_PATH . 'functions/display_messages.php');
     $string = "<font color=$color[2]><b>\n" . $title . "</b><br>\n";
-    if ($query != '')
+    $cmd = explode(' ',$query);
+    $cmd= strtolower($cmd[0]);
+
+    if ($query != '' &&  $cmd != 'login')
         $string .= _("Query:") . ' ' . htmlspecialchars($query) . '<br>';
     if ($message_title != '')
         $string .= $message_title;