lelutin / puppet-fail2ban

Manage fail2ban and its jails with puppet
GNU General Public License v3.0
8 stars 31 forks source link

Added before_include variable to RedHat section of fail2ban::config. #36

Closed rbdragon closed 6 years ago

rbdragon commented 6 years ago

I found with using the latest version of your module that numerous iptables errors were being produced. For example:

fail2ban.action [4063965]: ERROR <iptables> -N f2b-ssh <iptables> -A f2b-ssh -j <returntype> <iptables> -I INPUT -p tcp -m multiport --dports ssh -j f2b-ssh -- stderr: "/bin/sh: iptables: No such file or directory\n/bin/sh: -c: line 1: syntax error near unexpected tokennewline'\n/bin/sh: -c: line 1: <iptables> A f2b-ssh -j <returntype>'\n"

As you can see there is a new line after fail2ban.action [4063965]: ERROR <iptables> -N f2b-ssh (I got a similar error for every jail I set up with the module). I was able to fix this by using the same variable that is in the Debian section of fail2ban::config in the RedHat section.

lelutin commented 6 years ago

Hi there!

Thanks for reporting this issue. I'm curious what is your current setup to understand better which redhat release and fail2ban version is affected.

rbdragon commented 6 years ago

Hello,

Sure, our current set up is Scientific Linux 7.3 fail2ban 0.9.7 (both systemd and polling backends) Apache 2.4.6 and Nginx 1.12.2 (on different servers though) SSH 7.4p1 Ceph 12.2.4

lelutin commented 6 years ago

Hi! I've finally got around to merging this. thanks for your work! it'll be part of the next release, 3.1, that I expect to produce somewhat soon.

rbdragon commented 6 years ago

Thanks!

lelutin commented 6 years ago

I'm sorry it took soooooo much time. but we're getting to a better place. thanks for submitting this in the first place ;)

rbdragon commented 6 years ago

That's ok. Life gets in the way sometimes :)