2016-04-05 12:46:35 +02:00
|
|
|
|
|
|
|
Plugin: fail2ban
|
|
|
|
|
|
|
|
Description::
|
|
|
|
Zaf plugin for monitoring fail2ban with LLD
|
|
|
|
Credits
|
|
|
|
2014 dron, jiri.slezka@slu.cz
|
|
|
|
2016 limo, lukas.macura@slu.cz
|
|
|
|
::
|
|
|
|
|
|
|
|
# Version of the plugin.
|
2016-04-24 05:35:01 +02:00
|
|
|
Version: 0.4
|
2016-04-05 12:46:35 +02:00
|
|
|
|
|
|
|
# Url of plugin location to be able to update plugin
|
|
|
|
Url: https://raw.githubusercontent.com/limosek/zaf-plugins/master/fail2ban
|
|
|
|
|
|
|
|
# Homepage of plugin
|
|
|
|
Web: https://github.com/limosek/zaf-plugins/
|
|
|
|
|
|
|
|
# Maintainer
|
|
|
|
Maintainer: Lukas Macura <lukas@macura.cz>
|
|
|
|
|
|
|
|
# Dependencies
|
2016-12-05 12:22:44 +01:00
|
|
|
Depends-dpkg: dash fail2ban sudo
|
|
|
|
Depends-opkg: busybox fail2ban sudo
|
|
|
|
Depends-rpm: fail2ban sudo
|
|
|
|
Depends-bin: fail2ban-client sudo
|
2016-04-05 12:46:35 +02:00
|
|
|
|
2016-04-12 20:31:05 +02:00
|
|
|
Sudo: fail2ban-client %
|
2016-04-05 12:46:35 +02:00
|
|
|
|
|
|
|
Item banned_actual:
|
|
|
|
Description::
|
|
|
|
Returns number of currently banned IPs for jail
|
|
|
|
::
|
2016-04-21 15:29:20 +02:00
|
|
|
Parameters::
|
|
|
|
jail '' ''
|
|
|
|
::
|
2016-04-05 12:46:35 +02:00
|
|
|
Cmd: sudo fail2ban-client status $1 | grep "Currently banned:" | grep -o -E "[0-9]*"
|
|
|
|
/Item
|
|
|
|
|
|
|
|
Item banned_total:
|
|
|
|
Description::
|
|
|
|
Returns number of total banned IPs for jail
|
|
|
|
::
|
2016-04-21 15:29:20 +02:00
|
|
|
Parameters::
|
|
|
|
jail '' ''
|
|
|
|
::
|
2016-04-05 12:46:35 +02:00
|
|
|
Cmd: sudo fail2ban-client status $1 | grep "Total banned:" | grep -o -E "[0-9]*"
|
|
|
|
/Item
|
|
|
|
|
|
|
|
Item jail_discovery:
|
|
|
|
Description::
|
|
|
|
Returns discovered jails
|
|
|
|
::
|
2016-04-24 05:35:01 +02:00
|
|
|
Testparameters: yes
|
2016-04-21 15:29:20 +02:00
|
|
|
Script: sudo fail2ban-client status | grep "Jail list" |grep -E -o "([-[:alnum:]]*, )*[-[:alnum:]]*$" | zaf_discovery '{#F2BJAIL}'
|
2016-04-05 12:46:35 +02:00
|
|
|
/Item
|
|
|
|
|