RocketChat / RocketChat/Rocket.Chat
Inconsistent Login and Account Creation Behavior in Rocket.Chat login page
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Description:
There are inconsistencies in the login and account creation process, particularly when using the "Sign in with Google" option and then attempting to log in using email/username and password. The following behaviors are observed:
-
Sign in with Google (without setting a password)
(already created an account and entered the username).-
Expected: Attempting to log in with email/username should return an error indicating that the account does not have a password.
-
Actual: The error returned is "User not found."
-
https://github.com/user-attachments/assets/061eac2c-4c91-4cad-9b1b-4aba6c965744
-
-
Sign in with Google (after setting a password)
-
Expected: Logging in using email/username and password should work.
-
Actual: "User not found" error appears, and no logs are generated.
-
https://github.com/user-attachments/assets/32400d00-858b-4342-b8e3-cdcda94ac8b3
-
-
Account Creation and Username/Email Handling Issues :
( note : This method is performed when I have already created an account using sign in with google and then I have tried to create an account)-
If trying to create an account with an existing email but a unique username:
-
Expected: A UI error stating "Email is already in use. Try a different email."
-
log : The error message is unclear: {success: false, error: 'Something went wrong. Please check your credentials. [403]', errorType: 403}.
-
https://github.com/user-attachments/assets/424496b4-757c-4e3d-bb4a-5e7ca04605e1
-
Steps to reproduce:
-
Go to the login page.
-
Sign in using Google without setting a password.
-
Try logging in using email/username.
-
Observe the "User not found" error instead of a "No password set" error.
-
Set a password and try logging in with email/username.
-
Observe that the error "User not found" persists with no logs.
-
Attempt to create an account with an existing username.
-
Observe that the UI correctly shows "Username already exists."
-
Attempt to create an account with an existing email but a unique username.
-
Observe that the error message is unclear (Something went wrong. Please check your credentials. [403]).
Expected behavior:
-
When logging in with email/username without setting a password, the system should return an error indicating "This account doesn't have a password!" instead of "User not found."
-
When logging in after setting a password, authentication should succeed if credentials are correct; otherwise, an appropriate error should be displayed.
*If the email is already registered, the UI should clearly state "Email is already in use. Try a different email." instead of a generic error.
Actual behavior:
-
"User not found" error appears in cases where a "No password set" error is expected.
-
Logging in after setting a password still results in "User not found" with no logs.
-
The error message for duplicate email registration is unclear (Something went wrong. Please check your credentials. [403]).
Server Setup Information:
- using open.rocket.chat
Client Setup Information
- Desktop App or Browser Version: google and firefox
- Operating System:Ubuntu 24.04.1 LTS
Additional context
Relevant logs:
- Sign in with Google (without setting a password):
no logs generated. - Sign in with Google (after setting a password):
no logs are generated. - Account Creation and Username/Email Handling Issues:
### Error Log from `verifyErrors.js:34` ```json { "success": false, "error": "Something went wrong. Please check your credentials. [403]", "errorType": 403, "user": { "name": "dummy", "email": "dummyId296@gmail.com", "username": "dum.dum.unique", "pass": "No_pass123." } } ```
Proposed fixes
🔹 Fix 1: Upon login using email/username and password without setting up the password should give me this account does not have a password
🔹 Fix 2: Ensure Authentication Works After Setting a Password .
🔹 Fix 3: Improve Error Messages for Duplicate Email Registration
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 at the login page on open.rocket.chat and reproduce the Google sign-in, password login, and duplicate-email registration cases. Review the error reported at verifyErrors.js:34 and any available authentication logs. Done means each flow shows the specified password or duplicate-email message, and password login succeeds after a password is set.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- authentication, backend, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100