taylorthurlow / panda-motd

a utility for generating a more useful MOTD
MIT License
134 stars 6 forks source link

Add fail2ban component #25

Closed taylorthurlow closed 5 years ago

taylorthurlow commented 5 years ago

Per #24 I've implemented a fail2ban component. The first thought in the issue was to print ban statistics based on the logs themselves, but this means that we're unable to differentiate bans based on their jail name. I figured this was important so as it is, the component takes jail names and will print a total banned count and a currently banned count for each jail.

From the mentioned article, there is a section on getting statistics for each day - which is cool - so it might be worth adding another section to the component which will print global ban statistics for the last N number of days, even if it's not on a per-jail basis. More investigating needed.

Closes #24.