diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2006-05-03 16:38:45 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2006-05-03 16:38:45 +0000 |
commit | 58f4a0aac6c651e1f20c927ed3113079cbc369f6 (patch) | |
tree | 3f8b017b4f9bf44bbc340d92141d5fb5cd972a9a | |
parent | 768c1c64bb042a6f1dccad91ac71d8b4b68570fa (diff) | |
download | pfsense-packages-58f4a0aac6c651e1f20c927ed3113079cbc369f6.tar.gz pfsense-packages-58f4a0aac6c651e1f20c927ed3113079cbc369f6.tar.bz2 pfsense-packages-58f4a0aac6c651e1f20c927ed3113079cbc369f6.zip |
Add to log the windows username of who blacklisted a server
-rw-r--r-- | packages/spamd_db_ext.php | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/packages/spamd_db_ext.php b/packages/spamd_db_ext.php index 88164e60..85edb773 100644 --- a/packages/spamd_db_ext.php +++ b/packages/spamd_db_ext.php @@ -29,6 +29,8 @@ require("config.inc"); +if($_GET['loginname']) + $username = $_GET['loginname']; if($_GET['username']) $username = $_GET['username']; if($_GET['password']) @@ -71,7 +73,7 @@ if($_GET['action'] or $_POST['action']) { usleep(100); exec("/usr/local/sbin/spamdb -a {$srcip}"); mwexec("/sbin/pfctl -q -t blacklist -T replace -f /var/db/blacklist.txt"); - log_error("spamd: {$srcip} has been whitelisted by {$_SERVER['REMOTE_ADDR']}"); + log_error("spamd: {$srcip} has been whitelisted by {$_SERVER['REMOTE_ADDR']} {$loginname}"); hup_spamd(); exit; } else if($action == "delete") { @@ -80,7 +82,7 @@ if($_GET['action'] or $_POST['action']) { hup_spamd(); mwexec("/sbin/pfctl -q -t spamd -T delete $srcip"); mwexec("/sbin/pfctl -q -t blacklist -T replace -f /var/db/blacklist.txt"); - log_error("spamd: {$srcip} has been deleted by {$_SERVER['REMOTE_ADDR']}"); + log_error("spamd: {$srcip} has been deleted by {$_SERVER['REMOTE_ADDR']} {$loginname}"); exit; } else if($action == "spamtrap") { delete_from_spamd_db($email); @@ -88,14 +90,14 @@ if($_GET['action'] or $_POST['action']) { exec("/usr/local/sbin/spamdb -a \"<{$email}>\" -T"); hup_spamd(); mwexec("/sbin/pfctl -q -t blacklist -T add -f /var/db/blacklist.txt"); - log_error("spamd: {$srcip} has been blacklisted by {$_SERVER['REMOTE_ADDR']}"); + log_error("spamd: {$srcip} has been blacklisted by {$_SERVER['REMOTE_ADDR']} {$loginname}"); exit; } else if($action == "trapped") { delete_from_spamd_db($srcip); usleep(100); exec("/usr/local/sbin/spamdb -a {$srcip} -t"); add_to_blacklist($srcip); - log_error("spamd: {$srcip} has been trapped by {$_SERVER['REMOTE_ADDR']}"); + log_error("spamd: {$srcip} has been trapped by {$_SERVER['REMOTE_ADDR']} {$loginname}"); hup_spamd(); exit; } |