mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-02-05 00:29:40 +03:00
TOTP Token invalid since today #1142
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 @nicedevil007 on GitHub (Oct 25, 2021).
Subject of the issue
I was using vaultwarden over the last months or even years now (Bitwarden_RS before). I had enabled TOTP Tokens with Authy.
My token was all day long legit since today. It tells me that the token is wrong. The time shown in the error box is 2 hours off to my local time. I checked the time on my router, it is the right one, I checked the time on my PC, it is the right one, I checked the time of my vaultwarden docker container, it is the right, and yes you are right, the same for the host and nginxproxymanager.
Then I checked the admin page of my vaultwarden, and here we go => there is a red mark on the time. How can we fix it?
Deployment environment
Your environment (Generated via diagnostics page)
Config (Generated via diagnostics page)
Show Running Config
Environment settings which are overridden: DOMAIN, SIGNUPS_ALLOWED, ADMIN_TOKEN, INVITATION_ORG_NAME, SMTP_HOST, SMTP_SSL, SMTP_PORT, SMTP_FROM, SMTP_FROM_NAME, SMTP_USERNAME, SMTP_PASSWORD
Steps to reproduce
I guess I was clear enough? :)
Expected behaviour
TOTP Token will work again
Actual behaviour
TOTP Token with Authy or Google Authenticator isn't working.
Troubleshooting data
@cksapp commented on GitHub (Oct 25, 2021):
The 2 hour difference is because this is shown in UTC time. So you would locally be anywhere within these timezones
I would check the NTP on your server, as well as your browser. Might suggest opening up from a cell phone or another device off of wifi and over mobile data instead to see if you experience the same issues.
@nicedevil007 commented on GitHub (Oct 25, 2021):
it is not the 2 hour difference that is the problem, it is the ca. 1 min difference between browser/server on UTC
@cksapp commented on GitHub (Oct 25, 2021):
Correct, sorry if I wasn't clear about that there.
I recommend checking the NTP settings of your server and the web browser. As you've mentioned you have already checked the docker container and the reverse proxy for the correct time, I might suggest starting at looking on the browser and checking another browser from another device if possible.
Perhaps provide details on the web browser you are using as the client to access the web build.
This would also perhaps best be a topic for our forum.
@nicedevil007 commented on GitHub (Oct 25, 2021):
I'm using brave and tryed with MS edge and firefox as well. And also on 2 different device...
Maybe the battery of my client is low o_O? That screen is directly from the host
@nicedevil007 commented on GitHub (Oct 25, 2021):
Ok fixed it....

first
timedatectl set-local-rtc 1 --adjust-system-clockthentimedatectl set-local-rtc 0 --adjust-system-clockthenthen the output of
timedatectlwas:a restart of the docker container afterwards forced it to sync time now instead of waiting for next sync :)