From: Michael M Slusarz Date: Wed, 30 Jun 2010 20:04:29 +0000 (-0600) Subject: Clean up log entry output if not fully authenticated X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=e32e232b8aa734f9c3393b7ff460861b32b0e850;p=horde.git Clean up log entry output if not fully authenticated --- diff --git a/imp/lib/Auth.php b/imp/lib/Auth.php index 558869690..c1a9ce5c1 100644 --- a/imp/lib/Auth.php +++ b/imp/lib/Auth.php @@ -146,13 +146,13 @@ class IMP_Auth $imap_ob = $GLOBALS['injector']->getInstance('IMP_Imap')->getOb(); $msg = sprintf( - $status_msg . '%s [%s]%s to {%s:%s [%s]}', - $auth_id ? '' : ' for ' . $auth_id, + $status_msg . '%s [%s]%s to {%s:%s%s}', + !strlen($auth_id) ? '' : ' for ' . $auth_id, $_SERVER['REMOTE_ADDR'], empty($_SERVER['HTTP_X_FORWARDED_FOR']) ? '' : ' (forwarded for [' . $_SERVER['HTTP_X_FORWARDED_FOR'] . '])', $imap_ob ? $imap_ob->getParam('hostspec') : '', $imap_ob ? $imap_ob->getParam('port') : '', - empty($_SESSION['imp']['protocol']) ? '' : $_SESSION['imp']['protocol'] + empty($_SESSION['imp']['protocol']) ? '' : ' [' . $_SESSION['imp']['protocol'] . ']' ); Horde::logMessage($msg, $level);