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

Do not use Azure AD display name as username #213

Closed
thomas-rabiller-azimut opened this issue Sep 6, 2018 · 2 comments · Fixed by #280
Closed

Do not use Azure AD display name as username #213

thomas-rabiller-azimut opened this issue Sep 6, 2018 · 2 comments · Fixed by #280

Comments

@thomas-rabiller-azimut
Copy link

While using the AzureAdOAuthenticator to authenticate with Oauth to the Azure AD provider, the property "name" from the requested JWT token is used as username in JupyterHub. According to the Azure AD documentation:

The name claim provides a human-readable value that identifies the subject of the token. The value is not guaranteed to be unique, it is mutable, and it's designed to be used only for display purposes

It is therefore not reliable as a username (not unique, can contain spaces and special chars...)

I suggest using the object id instead, which is exactly the common unix username max size (32 chars long after removing the dashes in guid)

This is what I am doing currently in a project by overriding the behaviour in a inherited class, but it should probably be applied in future versions by default.

@cfoisy-osisoft
Copy link

Can you share your code or (better) provide a PR? We're planning to deploy our own hub on Azure and we'll surely need this fix.

@vwoloszyn
Copy link

I open an issue regarding this behavior of using the AD display name as username. In short, jupyterhub is not allowing to autheticate users because the display name contain an illegal char "/"
#529

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

Successfully merging a pull request may close this issue.

3 participants