mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-10-19 05:58:34 +02:00
Look for SPAM as well when filtering the mail log.
This commit is contained in:
@@ -297,12 +297,13 @@ class LogParser(object):
|
||||
if not m:
|
||||
return
|
||||
host, prog, pid, log = m.groups()
|
||||
m = re.search("(INFECTED|SPAMMY) .* <[^>]+> -> <[^@]+@([^>]+)>.*", log)
|
||||
m = re.search("(INFECTED|SPAM|SPAMMY) .* <[^>]+> -> <[^@]+@([^>]+)>.*",
|
||||
log)
|
||||
if m is not None:
|
||||
if m.group(2) in self.domains:
|
||||
if m.group(1) == 'INFECTED':
|
||||
self.inc_counter(m.group(2), 'virus')
|
||||
elif m.group(1) == 'SPAMMY':
|
||||
elif m.group(1) == 'SPAM' or m.group(1) == 'SPAMMY':
|
||||
self.inc_counter(m.group(2), 'spam')
|
||||
return
|
||||
m = self._id_expr.match(log)
|
||||
|
||||
Reference in New Issue
Block a user