-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(jans-cedarling)!: move TOKEN_CONFIGS into the token_metadata schema #10888
Comments
why we need |
and why we need |
Also, we need to define what key will be used as
or array of object:
Also, this approach allows extending if some requirements will be changed. __ |
We missed something--part of this was already done https://github.com/JanssenProject/jans/wiki/Cedarling-Nativity-Plan#token-entity-mapper
|
we should probably just remove that too so the user doesn't have to look at the bootstrap config for the mapping. I think it's a better user experience to have the settings regarding tokens with the token entity metadata schema. |
|
It was discussed to not use the Cedar schema as a way to define behavior anymore. |
Thanks for explanation, please don't forget to add it to documentation |
@rmarinn If this is a breaking change (requiring a major release) then you can change the title to |
Okay, i changed it. I misplaced the exclamation point |
Is your feature request related to a problem? Please describe.
Currently, defining and using tokens into requires a user to do 4 things:
1. Have the token defined in the
CEDARLING_TOKEN_CONFIGS
2. Have the entity of the token defined in the cedar schema
3. And define it in the Trusted Issuer Metadata Schema:
CEDARLING_TOKEN_ENTITY_MAPPER
bootstrap property as follows:This having to look at four places to figure out where the token entity will go introduces some confusion and could be improved.
Describe the solution you'd like
We can reduce this into two steps by moving removing the
CEDARLING_TOKEN_CONFIGS
then moving it's contents to the Trusted Issuer Metadata schema:Implementation:
"required_claims"
field in the respective token entity. If a required claim is a registered claim name under RFC 7519 Section 4.1, the claim will be validated."token_entity_name"
field in the respective token entity. Note that the token entity defined here MUST also be defined in the Cedar schema. Also note that the token name here will be how we reference the token in when callingCedarling.authorize()
."entity_mapping"
field in the respective token entity. Note that if an entity mapping is defined here, the entity MUST also be defined in the Cedar schema.Describe alternatives you've considered
Additional context
At the time of this writing, it was discussed that we'll settle for having to define the tokens in two places since it's still better than 3 places but we don't really want to touch the cedar schema.
The text was updated successfully, but these errors were encountered: