RocketChat / RocketChat/Rocket.Chat

Custom user information is not received from OAuth

Open
#19,985 6 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

feat: oauth / sso
Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

Description:

We have our own OAuth server and need to get some user information (only OAuth sub for now) from OAuth to send back in the livechat webhook events.

Steps to reproduce:
  1. Go to 'Accounts > Registration > Custom Fields'
  2. Set this json :
    {"sub" :{"type": "text","required": true}}
  3. Set 'Registration Form' to 'Disabled'
Expected behavior:

I was expecting to get the sub OAuth attribute in user information.

Actual behavior:

The custom field is not populated.

Server Setup Information:
  • Version of Rocket.Chat Server: 3.9.3
  • Operating System: Ubuntu 20.04
  • Deployment Method: docker
  • Number of Running Instances: 1
  • DB Replicaset Oplog: Default
  • NodeJS Version: docker one
  • MongoDB Version:4.0
Client Setup Information
  • Desktop App or Browser Version: Chrome
  • Operating System: Ubuntu 20.04

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the custom OAuth flow with the supplied custom-field JSON and disabled registration form, then trace how OAuth user information reaches livechat webhook events. Done means the OAuth sub attribute is populated in the user information sent by those webhook events.

Written by the indexing model from the issue text.

Assessment

Domain
api, authentication
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.