-
Notifications
You must be signed in to change notification settings - Fork 495
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
Bug in OAuth2 First Login page not using prefilled username from OAuth2UserRecord #6690
Comments
@poikilotherm as always, thanks for the bug report! Please go ahead and try to fix it! Thanks! 😄 |
Dear everyone. We also noticed this upon enabling OIDC for our organization. Would be nice to fill the user name as well. By the way, would |
@espenfl you are welcome to open an issue about this. Here's the code we use: https://github.com/IQSS/dataverse/blob/v5.2/src/main/java/edu/harvard/iq/dataverse/UserNameValidator.java#L36 |
This issue should be easier to work on now that developers have a simple way to spin up Keycloak on their laptops: By the way, @espenfl since I'm leaving a comment anyway, I'm not sure if you ever created a dedicated issue about supporting |
We use a OIDC connection for auth in our Dataverse, and we are also interested in having the username prefilled. I dug through the code some more and found this comment Lines 295 to 300 in cf174b2
I guess that the setNewUser method is still called from the following line, but I'm not so familiar with the code base yet... Line 128 in cf174b2
This would suggest that uncommenting the line |
To focus on the most important features and bugs, we are closing issues created before 2020 (version 5.0) that are not new feature requests with the label 'Type: Feature'. If you created this issue and you feel the team should revisit this decision, please reopen the issue and leave a comment. |
While playing with our new Jülich DATA Beta service, I discovered that the username set in the authentication provider is never used in the first login form. This should be changed.
Digging into the code. I set the field during auth:
dataverse/src/main/java/edu/harvard/iq/dataverse/authorization/providers/oauth2/oidc/OIDCAuthProvider.java
Lines 189 to 194 in 7227c38
But the view is simply requesting the
username
attribute, which is never set inOAuth2FirstLoginPage.init()
:dataverse/src/main/webapp/oauth2/firstLogin.xhtml
Lines 43 to 46 in 7227c38
As
alwaysmost of the time: happy to contribute. This looks like it was not left out on purpose, so dunno if we need a trigger for UI team or just go ahead and fix it.The text was updated successfully, but these errors were encountered: