RocketChat / RocketChat/Rocket.Chat
OAuth users are asked for their current password when trying to set a local password for the first time
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Description:
Users who registered via OAuth SSO might want to create a password for direct login with RC later on. If they try to do so via My Account -> Profile, they are presented with text fields to enter a new password, but upon submitting are asked to enter their current password as confirmation, which they do not have yet.
Steps to reproduce:
- Activate OAuth SSO via some provider (e.g. Google)
- Register a new Account via OAuth SSO and login to that account
- Go to My Account -> Profile
- Try to enter a new password (which would be the first password for that user) and the confirmation and submit
Expected behavior:
New password should submit and be set without asking for the current one as confirmation, since the user hasn't set a password yet, or fields for entering a new password should be deactivated for OAuth users.
Actual behavior:
Server asks for current password as confirmation, which is not known to the user.
Server Setup Information:
- Version of Rocket.Chat Server: 3.13.2
- Operating System: Ubuntu 20.04
- Deployment Method: snap
- Number of Running Instances: 1
- NodeJS Version: v12.21.0
- MongoDB Version: 3.6.14 / wiredTiger (oplog Enabled)
Client Setup Information
- Browser Version: Firefox 88.0.1 (64-bit)
- Operating System: Windows 10
Additional context
Admin-option Enforce password fallback under Accounts -> Two Factor Authentication is turned off
Workarounds
- Have an admin send a new (temporary) password to the user via email
- Forgot password option (not tested, but think that should work)
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 OAuth registration flow, then inspect the My Account → Profile password-setting path and how it handles users without an existing password. Done means an OAuth user can set a first local password without a nonexistent current-password confirmation, or the new-password fields are disabled for OAuth users.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- authentication
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100