mirror of https://github.com/fail2ban/fail2ban
Browse Source
Previously only the last line of the match was being saved, not all lines involved in matching. Log lines are now broken into 3 part tuple, with the line pre-datetime, the datetime, and post-datetime. Allows reformation of full line, but also use of the line without the datetime present. Attempting to use the term "tupleLine(s)" where possible, to avoid confusion with normal read lines. May also wish to consider that regexs could be made to capture more lines of interest if some form of unique reference is available. This may allow more lines of interest to be captured, which may not be picked up by the traditional "grep <ip>" approach i.e. ones which do not have the ip address in. This also simplified the fail2ban-regex statistics for missed lines. Also resolved bug with missed lines time extracted for debuggex having some lines present which were captured in a multiline regex. Also resolved independent issue with ignored line check including the datetime, which raised assertion error in the rare case the datetime matched the ignore regex, and the rest of line only matched a failregexpull/476/head
Steven Hiscocks
11 years ago
5 changed files with 100 additions and 85 deletions
Loading…
Reference in new issue