RocketChat / RocketChat/Rocket.Chat
E-Mail address input should be trimmed
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Description:
E-Mail addresses on the user creation form /admin/users/new and on the login (web, possibly mobile as well) screen are not trimmed. This allows to accidentially create user accounts with leading or trailing whitespaces. Users will still receive the welcome e-mail but won't be able to login without replicating the e-mail address with the leading or trailing whitespaces.
Steps to reproduce:
Admin mistake
- Go to /admin/users/new
- Create a new account with the E-Mail set to " test@example.com" or "test@example.com ".
- Logout.
- Try to login using "test@example.com" afterwards.
User mistake
- Go to /admin/users/new
- Create a new account with the E-Mail set to "test@example.com".
- Logout.
- Try to login using " test@example.com" or "test@example.com " afterwards.
Expected behavior:
I expect both forms to be fault tolerant and trim whitespace at the beginning and end of the e-mail address.
Actual behavior:
Whitespace is not trimmed in either form.
Server Setup Information:
- Version of Rocket.Chat Server: 6.5.2.
- Operating System: Ubuntu 22.04 LTS
- Deployment Method: Docker
- Number of Running Instances: 1
- DB Replicaset Oplog:
- NodeJS Version:
- MongoDB Version:
Client Setup Information
- Desktop App or Browser Version: Firefox 121.0
- Operating System:
Additional context
Relevant logs:
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue at /admin/users/new and on the web login screen with leading and trailing whitespace in the e-mail address. Verify that both forms trim whitespace so accounts can be created and users can log in using the untrimmed address.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- authentication, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100