-
Notifications
You must be signed in to change notification settings - Fork 936
Description
Product Version : IS 5.9.0 RC2
Scenario: OIDC authorization flow with users role claim as a requested attributes
id_token
{ "at_hash": "7nv58bbnP015IeXKUKZ3xA", "sub": "[email protected]", "amr": [ "BasicAuthenticator" ], "iss": "https://localhost:9443/oauth2/token", "groups": [ "Internal/everyone", "dev" ], "given_name": "Farasath", "aud": "4anu0JXj4o_66UIrkwP0Y8ujUDka", "c_hash": "Ylhe_YCmiNDjUvSJQUKc8w", "nbf": 1570087119, "azp": "4anu0JXj4o_66UIrkwP0Y8ujUDka", "exp": 1570090719, "iat": 1570087119, "family_name": "Ahamed", "email": "[email protected]" }
user info response
{ "sub": "[email protected]", "groups": "Internal/everyone,dev", "given_name": "Farasath", "family_name": "Ahamed", "email": "[email protected]" }
If you consider the "groups" claim which is a multi-valued claim. In the id_token it is returned as a JSON array while in the user info response it is returned as a string with values appended using the multi-attribute separator.
The user info response needs to consistent with the id_token value.
Issue:
The code segment [1], returns the claim values used to build the user info JSON. We need to make sure that the claims are in the correct format. ie. handle multi-attribute values.
We do similar formatting in the id token builder [2]