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

Initial docker and nginx conf updates for keycloak #618

Closed
wants to merge 11 commits into from

Conversation

isedwards
Copy link
Member

This updated PR for keycloak integration uses the Flask-OIDC package with wis2box-auth (replacing a previous implementation that used oauth2-proxy independently of Flask).

Currently it requires manually changing the hard coded IP address (currently 10.211.55.15 in nginx.conf) to instead be the value of $WIS2BOX_URL.

This version uses the following branch of wis2box-auth which interfaces to keycloak using Flask-OIDC: https://github.com/isedwards/wis2box-auth/tree/initial-keycloak

I'll submit an update later today that

  • Uses envsubst to update the host URL to the value of $WIS2BOX_URL when the nginx container is built
  • Includes docs for setting up the keycloak instance (currently accessed at <IP-ADDRESS>:8180).

When nginx uses the auth_request directive, this calls the wis2box-auth authorize endpoint as before. However, instead of validating a token it checks whether the current user's browser has an authenticated session with keycloak (see wis2box_auth/app.py#L69-L7 for the simplified version).

I'm in the process of replacing wis2box-auth's add_token and remove_token with an equivalent add_group and remove_group which will be used to grant access based on group membership. User's group credentials are configured in keycloak.

@isedwards isedwards marked this pull request as draft January 23, 2024 07:49
@tomkralidis
Copy link
Collaborator

Closing for now while the wis2box team is re-evaluating access control requirements.

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 this pull request may close these issues.

2 participants