Skip to content
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

Authenticate with scope=openid to be able to retrieve all user attributes #38

Open
Fideldue opened this issue Jan 17, 2024 · 0 comments

Comments

@Fideldue
Copy link

This is more of a feature request to support all user attributes than a bug.
I could not retrieve custom user attributes via the userdata values and wanted to know what might be the issue since the userInfo endpoint from Cognito is providing them.

According to stackoverflow scope need to be defined as scope=openid during the authentication.

A short tryout with adding this to the build of the url in get_url_auth_redirect, it can retrieve all user attributes including the custom ones.

...
 aws_auth_redirect <- paste0(cognito_config$base_cognito_url, 
    "/oauth2/authorize?", "scope=openid", "&", "response_type=", 
    cognito_config$oauth_flow, "&", "client_id=", cognito_config$app_client_id, 
    "&", "redirect_uri=", cognito_config$redirect_uri, "&", 
    paste0("state=", params))
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant