mirror of https://github.com/fail2ban/fail2ban
use raw host (don't use textToIp) if usedns exactly `raw`, because `usedns = no` should ignore no ip failures
parent
c33e25bab6
commit
8ec4e1189e
|
@ -94,6 +94,7 @@ backend = auto
|
|||
# but it will be logged as a warning.
|
||||
# no: if a hostname is encountered, will not be used for banning,
|
||||
# but it will be logged as info.
|
||||
# raw: use raw value (no hostname), allow use it for no-host filters/actions (example user)
|
||||
usedns = warn
|
||||
|
||||
# "logencoding" specifies the encoding of the log files handled by the jail
|
||||
|
|
|
@ -523,7 +523,7 @@ class Filter(JailThread):
|
|||
self.__lineBuffer = failRegex.getUnmatchedTupleLines()
|
||||
try:
|
||||
host = failRegex.getHost()
|
||||
if returnRawHost or self.__useDns not in ("yes", "warn"):
|
||||
if returnRawHost or self.__useDns == "raw":
|
||||
failList.append([failRegexIndex, host, date,
|
||||
failRegex.getMatchedLines()])
|
||||
if not checkAllRegex:
|
||||
|
|
Loading…
Reference in New Issue