mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-07-17 01:12:27 -05:00
Websocket error log cannot be disabled #4845
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @pichouk on GitHub (Jan 24, 2022).
Websocket error log cannot be disabled
When I set the variable
LOG_LEVEL = "off"I still have log messages because of websocket malformed requests.Deployment environment
I deployed Vaultwarden using Kubernetes, on AWS. I use the container image
vaultwarden/server:1.23.1.I expose Vaultwarden using a AWS Application Load Balancer, which regularly send healtchecks to the container. Those healthchecks does not support Websocket, and I can't disable them. So I have malformed requests on the Websocket port.
I just want to hide the error message generated by the container when receiving a bad request on Websocket port.
Steps to reproduce
Start a Vaultwarden server with
LOG_LEVEL="off"and send an HTTP request (using curl) to the websocket port.Expected behaviour
I think those error logs should not be present when using the
LOG_LEVEL="off"configuration.Actual behaviour
I still have this messages
@BlackDex commented on GitHub (Jan 24, 2022):
This is not something we can fix, since this is build-in into the library used for the websockets.
24511a9d4b/src/handler.rs (L63-L70)Also, if you see this error, then you probably have configured your reverse proxy incorrect, or, if not using a reverse proxy you need to disable websockets at all via
WEBSOCKET_ENABLED=FALSE.Also see: https://github.com/dani-garcia/vaultwarden/wiki/Enabling-WebSocket-notifications
And https://github.com/dani-garcia/vaultwarden/wiki/Proxy-examples