Replies: 2 comments
-
Same issue here! Installed fail2ban using apt on Ubuntu Server, Vaultwarden is on docker. Fail2ban is pulling IPs from the vaultwarden.log just fine, but is unable to successfully ban IPs. A few excerpts from my fail2ban.log:
And my /etc/fail2ban/jail.d/vaultwarden.local:
The last part is added because of the wiki's note for docker users. Please let me know if I misunderstood! |
Beta Was this translation helpful? Give feedback.
-
For it works if I manually ban using the command. but its not working automatically. Anyone found the fix?
sudo nano vaultwarden.local
sudo nano vaultwarden.local
|
Beta Was this translation helpful? Give feedback.
-
I've followed the tutorial through several times now because I've gotten frustrated I've wiped my VQ vm and started from scratch about three times now. I just can't get fail2ban to work according to the instructions alone.
I have vaultwarden installed (docker container of course), and fail2ban installed directly. I have nginx proxy manager as the reverse proxy in a separate vm. I have a let's encrypt SSL installed etc etc. no issues with access whatsoever.
I set up my jail.d/vaultwarden.local exactly as the tutorial says. I set up my filter.d/vaultwarden.local exactly as the tutorial says. I have the jal looking at the correct log file path. I can see the external IPs being logged on failed login attempts. Running fail2ban-regex correctly matches the failed logins in the log with the filter regex string. But nothing happens. iptables doesn't get any entries, nothing shows as banned in fail2ban-client status vaultwarden. But even if I manually ban an IP it shows as banned in fail2ban-client status but i still have access anyway, nothing in iptables.
I am going out of my mind because I've gone over everything (and there isn't that much to go over) and I just can't work out why it isn't working. I haven't done any config in any action .conf files because the tutorial doesn't say to touch anything there. I've just done what the tutorial said and it just doesn't work. Someone please help, if you have the same or similar setup please help me out here.
I've confirmed the f2b log is getting the correct external client IP too. Except it just does nothing. I'm absolutely out of ideas.
Beta Was this translation helpful? Give feedback.
All reactions