-
-
Notifications
You must be signed in to change notification settings - Fork 369
hMailserver
Jeff Johnson edited this page Sep 15, 2020
·
7 revisions
hMailServer is a free and open source mail server.
To add hMailserver SMTP and IMAP protection, add this block to the config file:
<!-- hMailserver failed logins, Windows, at least SMTP or POP3 ord IMAP logs must be turned on! -->
<LogFile>
<Source>hMailserver</Source>
<PathAndMask>
C:/Program Files/hMailserver/logs/**/*.log
C:/Program Files (x86)/hMailserver/logs/**/*.log
</PathAndMask>
<FailedLoginRegex>
<![CDATA[
^".*\t.*\t.*\t"(?<timestamp>.+)"\t"(?<ipaddress>.+)"\t.*(?:Authentication failed|Invalid user name or password).*$
]]>
</FailedLoginRegex>
<FailedLoginRegexTimestampFormat>yyyy-MM-dd HH:mm:ss.fff</FailedLoginRegexTimestampFormat>
<PlatformRegex>Windows</PlatformRegex>
<PingInterval>10000</PingInterval>
<MaxFileSize>16777216</MaxFileSize>
</LogFile>
To get this working you must activate SMTP and IMAP logging in the admin interface of hMailserver. There are hidden options to reduce the logging verbosity via the server's .ini file: hMailserver official forum
You may want to use LogLevel=1
(lowest) together with MaxLogLineLen=250
. It still includes the failed logins and truncates the IMAP log lines to 250 characters per line.
IPBan (c) 2012-Present Digital Ruby, LLC - https://ipban.com