-
Notifications
You must be signed in to change notification settings - Fork 16
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
Feature/354 openid auth #1007
Feature/354 openid auth #1007
Conversation
Still thinking of ways to automate testing this without going overboard. |
* Add extension to start keycloak instance. * Configure OpenID parameters for test CDA instance. * Add additional user to keycloak that intentionally doesn't have privileges * Verify keycloak user with priveleges works.
cwms-data-api/src/main/java/cwms/cda/security/OpenIDAccessManager.java
Outdated
Show resolved
Hide resolved
cwms-data-api/src/main/java/cwms/cda/security/OpenIDAccessManager.java
Outdated
Show resolved
Hide resolved
cwms-data-api/src/main/java/cwms/cda/security/OpenIDAccessManager.java
Outdated
Show resolved
Hide resolved
cwms-data-api/src/test/java/cwms/cda/api/auth/OpenIdConnectTestIT.java
Outdated
Show resolved
Hide resolved
I'm not in a position to test this on my own. The changes look ok but there are several things here that I don't entirely understand. Not in a "I'm confused about it" sense but in the sense that I don't know any of the details so I don't have an opinion. |
cwms-data-api/src/test/java/fixtures/CwmsDataApiSetupCallback.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The random getProperty call still needs to be fixed - right?
Adds support for initial user creation from a trusted JWT.
NOTES:
Uses the "principle_name" (note: spelled incorrectly in database) field to store the combination of JWT issuer and subject claim . The subject is a UUID and so the combination of issue+subject is always unique. This was done after discovering that the one of the test infrastructure OIDC providers doesn't include the CAC EDIPI anywhere and it could not be used for user lookup.
Using a full identity provider principal is better anyways, so may as well start here.
Additionally updates the docker-compose to require no external setup. This should make testing and development far easier for newcomers to the project.