Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| howto:fail2ban [2020/07/02 22:59] – add rules for hack / spam logs ragnarok | howto:fail2ban [2025/08/18 14:15] (current) – Updated filter for hack.log, now matching all hack attempts, not just FTP Karloch | ||
|---|---|---|---|
| Line 25: | Line 25: | ||
| maxretry = 3 | maxretry = 3 | ||
| findtime = 21600 | findtime = 21600 | ||
| + | bantime = 21600 | ||
| + | |||
| + | [sbbs-ddos] | ||
| + | enabled | ||
| + | filter | ||
| + | action | ||
| + | logpath | ||
| + | maxretry = 8 | ||
| + | findtime = 600 | ||
| bantime = 21600 | bantime = 21600 | ||
| Line 65: | Line 74: | ||
| failregex = Bad password from: < | failregex = Bad password from: < | ||
| Throttling suspicious connection from: < | Throttling suspicious connection from: < | ||
| + | ignoreregex = | ||
| + | </ | ||
| + | |||
| + | Filter for ddos (/ | ||
| + | < | ||
| + | [INCLUDES] | ||
| + | before = common.conf | ||
| + | |||
| + | [Definition] | ||
| + | failregex = !Maximum concurrent connections without login (.*) reached from host: < | ||
| ignoreregex = | ignoreregex = | ||
| </ | </ | ||
| Line 73: | Line 92: | ||
| before = common.conf | before = common.conf | ||
| [Init] | [Init] | ||
| - | maxlines=6 | + | maxlines = 3 |
| [Definition] | [Definition] | ||
| - | failregex = ^SUSPECTED | + | failregex = ^SUSPECTED |
| + | datepattern = {}(?: | ||
| ignoreregex = | ignoreregex = | ||
| </ | </ | ||
| Line 86: | Line 106: | ||
| failregex = .* !TEMPORARY BAN of .* < | failregex = .* !TEMPORARY BAN of .* < | ||
| SMTP BLACKLISTED SERVER on .* \(.*\)\: .* \[< | SMTP BLACKLISTED SERVER on .* \(.*\)\: .* \[< | ||
| + | ^.*\[< | ||
| ignoreregex = | ignoreregex = | ||
| </ | </ | ||
| Line 105: | Line 126: | ||
| Status | Status | ||
| |- Number of jail: 7 | |- Number of jail: 7 | ||
| - | `- Jail list: | + | `- Jail list: |
| </ | </ | ||
| Line 135: | Line 156: | ||
| RETURN | RETURN | ||
| + | Chain fail2ban-SBBS-ddos (1 references) | ||
| + | target | ||
| + | REJECT | ||
| + | RETURN | ||
| </ | </ | ||
| - | |||
| ===== See Also ===== | ===== See Also ===== | ||
| * [[: | * [[: | ||