cryostatio / cryostat-web

Web front-end for Cryostat: Secure JDK Flight Recorder management for containerized JVMs
https://cryostat.io/
Other
10 stars 20 forks source link

fix(auth): force reload to / on any logout result #1237

Closed andrewazores closed 4 months ago

andrewazores commented 4 months ago

Welcome to Cryostat! 👋

Before contributing, make sure you have:

To recreate commits with GPG signature git fetch upstream && git rebase --force --gpg-sign upstream/main


See https://github.com/cryostatio/cryostat-helm/pull/131#issuecomment-2052411429

Description of the change:

Force reload to application root path on any signout response, success or failure or error.

How to manually test:

  1. See https://github.com/cryostatio/cryostat-helm/pull/131#issuecomment-2052411429 for the k8s/OpenShift case, or use cryostat3 smoketest for a simple oauth2 proxy case
  2. Build an image including this PR, or use the image quay.io/andrewazores/cryostat:3.0.0-logout-refresh-1
  3. Test logging in and then logging out. In all cases (OAuth2 proxy with htpasswd Basic, openshift-oauth-proxy with only OpenShift SSO, or openshift-oauth-proxy with OpenShift SSO + htpasswd Basic), logging out from the UI should kick the browser back out to the auth proxy sign in page. Refreshing from here or reopening the URL in a new tab/window should still result in the sign in page (session has been cleared). Logging back in again should work as expected.