Преглед изворни кода

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;