mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-04-26 01:35:54 +03:00
[GH-ISSUE #2348] trim() the login email field: Android might add trailing spaces #1231
Labels
No labels
SSO
Third party
better for forum
bug
bug
documentation
duplicate
enhancement
future Vault
future Vault
future Vault
good first issue
help wanted
low priority
notes
pull-request
question
troubleshooting
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vaultwarden#1231
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
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 @hitech95 on GitHub (Mar 2, 2022).
Original GitHub issue: https://github.com/dani-garcia/vaultwarden/issues/2348
Subject of the issue
Android might add trailing space to email on login input
Deployment environment
Install method: Docker Compose
Clients used: Android Client
Reverse proxy and version: traefik v2
PostgreSQL version: PostgreSQL 11.15 (Debian 11.15-1.pgdg90+1) on x86_64-pc-linux-gnu
Other relevant details:
Steps to reproduce
[2022-03-02 22:12:09.086][vaultwarden::api::identity][ERROR] Username or password is incorrect. Try again. IP: x.x.x.x. Username: xxxxxx@gmail.com .https://github.com/dani-garcia/vaultwarden/blob/main/src/api/identity.rs#L104
The issue seems not to be present using the official server. (I have not tried with self hosted one)
Expected behaviour
Server perform trim on input email berfore looking for the user in the database.
Actual behaviour
Login is rejected
Troubleshooting data
@jeda commented on GitHub (Mar 3, 2022):
Can reproduce on web vault too. Since autocomplete is happy to do this, it's probably best user-experience speaking if it is trimmed, for safety.
(For some reason though,
/api/accounts/preloginsends{ email: "test@example.com" }while/identity/connect/tokensends{ "username": "test@example.com " }. Weird.)