RocketChat / RocketChat/Rocket.Chat
User Data Field Map in SAML Settings Example template wrong
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Description:
User Data Field Map in SAML Settings Example template wrong
Steps to reproduce:
Using the Template results in Full Name being "{{firstName}} {{lastName}}" the literal string via SAML login.
I got digging in the code and found that it should be "__firstName__ __lastName__"
The change was introduced in commit.
fd3532d4f5cfc8d714d6b036c7ebd793b27e7dc2
This is what effected me, but I assume there are more of this, where __ accidentally were replaced with {{ or }}
It is incredibly confusing and frustrating when an example is not working and you have to dig into the code base.
Expected behavior:
{"email": "mail","username": {"fieldName": "mail","regex": "(.*)@.+$","template": "user-regex"}, "name": { "fieldNames": ["firstName", "lastName"], "template": "__firstName__ __lastName__"}, "{{identifier}}": "uid"}
Actual behavior:
{"email": "mail","username": {"fieldName": "mail","regex": "(.*)@.+$","template": "user-regex"}, "name": { "fieldNames": ["firstName", "lastName"], "template": "{{firstName}} {{lastName}}"}, "{{identifier}}": "uid"}
I Highlighted the wrong section.
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 in apps/meteor/app/meteor-accounts-saml/server/lib/Utils.ts around line 124 and compare the SAML Settings Example template with commit fd3532d4f5cfc8d714d6b036c7ebd793b27e7dc2. Check whether other example placeholders were similarly changed. Done means the name template uses the expected double-underscore placeholders and no affected example retains the literal {{firstName}} form.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- authentication
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100