summaryrefslogtreecommitdiff
path: root/postfix/purge-spam-from-queue.sh
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2003-03-29 10:25:31 +0000
committerJonas Smedegaard <dr@jones.dk>2003-03-29 10:25:31 +0000
commitba6262eab669ef792cb515525fefcaf3140ecd9f (patch)
tree2b20f4fab68757efe095aa4274057d226b43a487 /postfix/purge-spam-from-queue.sh
parentc8b4f2046fc4adda16f3ef68e2d498214390d1e2 (diff)
Tighten filter, and include mails from MAILER-DAEMON (and mention spam as cause in the comment).
Diffstat (limited to 'postfix/purge-spam-from-queue.sh')
-rwxr-xr-xpostfix/purge-spam-from-queue.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/postfix/purge-spam-from-queue.sh b/postfix/purge-spam-from-queue.sh
index 13b0a60..97053ad 100755
--- a/postfix/purge-spam-from-queue.sh
+++ b/postfix/purge-spam-from-queue.sh
@@ -3,14 +3,14 @@
# /etc/local-COMMON/postfix/purge-spam-from-queue.sh
# Copyright 2002 Jonas Smedegaard <dr@jones.dk>
#
-# $Id: purge-spam-from-queue.sh,v 1.2 2002-12-31 13:38:42 jonas Exp $
+# $Id: purge-spam-from-queue.sh,v 1.3 2003-03-29 10:25:31 jonas Exp $
#
-# Purge non-important mails hanging in the queue (probably because of bounce to full mailbox)
+# Purge non-important mails hanging in the queue (probably because of bounce to full mailbox or spam rejections)
#
# TODO: Improve filter!
#
-badmails=`mailq | egrep -v '^( |$)' | egrep '@(earthlink\.net|yahoo\.com|excite\.com|hotmail\.com)' | sed 's/[^[:alnum:]].*//'`
+badmails=`mailq | egrep -v '^( |$|\(|-)' | egrep '(MAILER-DAEMON|@earthlink\.net|@yahoo\.com|@excite\.com|@hotmail\.com)$' | sed 's/[^[:alnum:]].*//'`
for x in $badmails; do
postsuper -d $x