gitea: After login providing two-factor auth 5XX errors. Can't login.
- Gitea version (or commit ref): 1.12.3
- Git version: 2.24.3
- Operating system: Docker container https://hub.docker.com/layers/gitea/gitea/1.12.3/images/sha256-38b8222941d8acffb7bb9c3fb0e9e0b657e06815a090f1fb11ed6900a3c9f384?context=explore
- Database (use
[x]):- PostgreSQL
- MySQL
- MSSQL
- SQLite
- Can you reproduce the bug at https://try.gitea.io:
- Yes (provide example URL)
- No
- Not relevant
Description
When logging in, and after proving a correct two-factor auth token, I am shown a 5XX error. The logs don’t provide a stack trace so can’t see where in the code it’s breaking.
[Macaron] 2020-08-01 23:10:07: Started POST /user/two_factor for 10.244.1.1
[Macaron] 2020-08-01 23:10:07: Completed POST /user/two_factor 500 Internal Server Error in 19.568867ms
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 15 (6 by maintainers)
I was able to work around this by getting a shell into PostgreSQL and running:
Note that
uuid = 111does not exist, but this prevented the two-factor auth screen from showing when logging in. Not sure what happened. An interesting note, is I did go enable two-factor auth again for my same user, logout, then log back in and it worked using two-factor without a 5XX error.After that I went and deleted the old (broken) two-factor entry in PostgreSQL manually: