From 5e0045b128b46cd9611d86731803bc3a910cd275 Mon Sep 17 00:00:00 2001 From: svncommit <devs@roundcube.net> Date: Fri, 06 Jun 2008 07:11:30 -0400 Subject: [PATCH] Add option to log successful logins. --- index.php | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/index.php b/index.php index ea62f9a..9f4d914 100644 --- a/index.php +++ b/index.php @@ -86,6 +86,13 @@ // send auth cookie if necessary $RCMAIL->authenticate_session(); + // log successful login + if ($RCMAIL->config->get('log_logins') && $RCMAIL->config->get('debug_level') & 1) + console(sprintf('Successful login for %s (id %d) from %s', + trim(get_input_value('_user', RCUBE_INPUT_POST), ' '), + $_SESSION['user_id'], + $_SERVER['REMOTE_ADDR'])); + // send redirect header("Location: {$RCMAIL->comm_path}"); exit; -- Gitblit v1.9.1