Replies: 1 comment 1 reply
-
From the IP range (which was reserved for private use and is probably from your docker networks) my guess is that you are not propagating the real IP address to Vaultwarden. So you might want to look into that. Regarding the second question: You would be limited by the available disk space. You can set up logrotate. Cf. this example in the wiki. Alternatively (instead of setting |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm running it in docker, here's my docker run command:
docker run -d --name vaultwarden \ -v /home/Wi-Fi/Bitwarden/:/data/ \ -v /home/Wi-Fi/Bitwarden/log/:/data/log/ \ -v /etc/localtime:/etc/localtime:ro \ -p 127.0.0.1:8001:80 \ --restart=always \ -e LOG_FILE=/data/log/vaultwarden.log \ vaultwarden/server:latest
I can now see in the host under /home/Wi-Fi/Bitwarden/log/vaultwarden.log
[2024-04-10 19:27:19.785][vaultwarden::api::identity][ERROR] Username or password is incorrect. Please retry. ip: 172.22.159.50. username: xxxxxxx@gmail.com.
Then I followed the documentation and created a new
/etc/fail2ban/filter.d/vaultwarden.log
and
/etc/fail2ban/jail.d/vaultwarden.local
Then I reloaded fail2ban and then I tried several times to enter the wrong account password and saw the corresponding logs, but it was not blocked,I can still access the page normally even though there is an ip being banned.
By the way, I'd like to ask about this.
/home/Wi-Fi/Bitwarden/log/vaultwarden.log file will be infinitely large? Is there any way I can limit its maximum size or keep it for only 1 day?
Beta Was this translation helpful? Give feedback.
All reactions