| Line 22... |
Line 22... |
| 22 |
# Option: actionstart
|
22 |
# Option: actionstart
|
| 23 |
# Notes.: command executed once at the start of Fail2Ban.
|
23 |
# Notes.: command executed once at the start of Fail2Ban.
|
| 24 |
# Values: CMD
|
24 |
# Values: CMD
|
| 25 |
#
|
25 |
#
|
| 26 |
actionstart = ipset create f2b-<name> hash:ip timeout <bantime>
|
26 |
actionstart = ipset create f2b-<name> hash:ip timeout <bantime>
|
| 27 |
iptables -I <chain> -p <protocol> -m multiport --dports <port> -m set --match-set f2b-<name> src -j <blocktype>
|
27 |
<iptables> -I <chain> -p <protocol> -m multiport --dports <port> -m set --match-set f2b-<name> src -j <blocktype>
|
| 28 |
|
28 |
|
| 29 |
# Option: actionstop
|
29 |
# Option: actionstop
|
| 30 |
# Notes.: command executed once at the end of Fail2Ban
|
30 |
# Notes.: command executed once at the end of Fail2Ban
|
| 31 |
# Values: CMD
|
31 |
# Values: CMD
|
| 32 |
#
|
32 |
#
|
| 33 |
actionstop = iptables -D <chain> -p <protocol> -m multiport --dports <port> -m set --match-set f2b-<name> src -j <blocktype>
|
33 |
actionstop = <iptables> -D <chain> -p <protocol> -m multiport --dports <port> -m set --match-set f2b-<name> src -j <blocktype>
|
| 34 |
ipset flush f2b-<name>
|
34 |
ipset flush f2b-<name>
|
| 35 |
ipset destroy f2b-<name>
|
35 |
ipset destroy f2b-<name>
|
| 36 |
|
36 |
|
| 37 |
# Option: actionban
|
37 |
# Option: actionban
|
| 38 |
# Notes.: command executed when banning an IP. Take care that the
|
38 |
# Notes.: command executed when banning an IP. Take care that the
|