Skip to content

Commit

Permalink
amend to 3f04cba: sendmail-auth has 2 failregex now, so rewritten wit…
Browse files Browse the repository at this point in the history
…h prefregex
  • Loading branch information
sebres committed Aug 27, 2020
1 parent 3f04cba commit db1f347
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions config/filter.d/sendmail-auth.conf
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ before = common.conf
[Definition]

_daemon = (?:sendmail|sm-(?:mta|acceptingconnections))
# "\w{14,20}" will give support for IDs from 14 up to 20 characters long
__prefix_line = %(known/__prefix_line)s(?:\w{14,20}: )?
addr = (?:IPv6:<IP6>|<IP4>)

# "w{14,20}" will give support for IDs from 14 up to 20 characters long
failregex = ^%(__prefix_line)s(\S+ )?\[%(addr)s\]( \(may be forged\))?: possible SMTP attack: command=AUTH, count=\d+$
^%(__prefix_line)sAUTH failure \(LOGIN\):(?: [^:]+:)? authentication failure: checkpass failed, user=<F-USER>(?:\S+|.*?)</F-USER>, relay=(?:\S+ )?\[%(addr)s\](?: \(may be forged\))?$
prefregex = ^<F-MLFID>%(__prefix_line)s</F-MLFID><F-CONTENT>.+</F-CONTENT>$

failregex = ^(\S+ )?\[%(addr)s\]( \(may be forged\))?: possible SMTP attack: command=AUTH, count=\d+$
^AUTH failure \(LOGIN\):(?: [^:]+:)? authentication failure: checkpass failed, user=<F-USER>(?:\S+|.*?)</F-USER>, relay=(?:\S+ )?\[%(addr)s\](?: \(may be forged\))?$
ignoreregex =

journalmatch = _SYSTEMD_UNIT=sendmail.service
Expand Down

0 comments on commit db1f347

Please sign in to comment.