I just set up TLJH and I like it
We are using AWS Cognito to federate our PingID based SSO solution. There is a custom claim custom:department that contains the user’s department as a string.
I cant wrap my head around it - it does not work like this because I think the code expects a list/array.
c.GenericOAuthenticator.claim_groups_key = "custom:department"
c.GenericOAuthenticator.allowed_groups = ["A B CC D"]
How can I configure the “callable” that converts the single string in the custom:department claim into the needed structure so that I can work with allowed_groups and add the permitted departments in that list?
Yes I expected the same but I get a 403 forbidden when configuring the settings like that - but I am in that department.
So I wanted to play around with the ‚callable‘ but have no clue.
def claim_groups_key_func(user_data_resp_json):
# Do something with user_data_resp_json
return groups
c.GenericOAuthenticator.claim_groups_key = claim_groups_key_func