itskenny0 / fail2ban-endlessh

Combining the powers of endlessh and fail2ban.
The Unlicense
190 stars 9 forks source link

added action file for firewalld #3

Closed eetommyj closed 2 years ago

eetommyj commented 2 years ago

Created a version of the action file that creates rules in firewalld.

I tested it with both ipv4 and ipv6 addresses and the tag should mark things correctly. I used openSUSE Tumbleweed with kernel 5.18.9-1 and it appears to be doing the trick. The remove rules also works, I see the rules go away when fail2ban is stopped as a service.

The iptables version of the file didn't work for me because my openSUSE version didn't have the kernel modules for iptables and its NAT. This it forced me to make a firewalld version (necessity being a mother to such things). Maybe this will be helpful for other people who use firewalld.

itskenny0 commented 2 years ago

Merged - thank you for the contribution!