joshp23 / YOURLS-OIDC

OpenID Connect Authentication for YOURLS
GNU General Public License v3.0
7 stars 6 forks source link

Honor redirect URLs upon logging in and out. #1

Closed yrammos closed 3 years ago

yrammos commented 4 years ago

The plugin does authorize the user with the Identity Provider but fails to actually load the YOURLS /admin page after logging in. (On my system, only a blank page is displayed; one needs to manually refresh the browser in order to proceed.)

No signout page is displayed, either, because the log-out link YOURLS_SITE is not a webpage, whereas YOURLS_SITE/admin is.

This PR attempts to fix both issues.

Thank you for a very useful plugin.

joshp23 commented 4 years ago

In my environment the redirect on login takes me to /admin, and logout redirects me to the public html page, reliably.

joshp23 commented 4 years ago

A better way to handle the logout redirect would be to set this manually as a config option. I prefer mine to redirect to the public page, but it seems as if you would prefer yours to redirect to the login page. The issue with redirecting to the login page is that it will, as currently designed take the user to the OIDC login page instead, which I find undesirable.

yrammos commented 3 years ago

@joshp23 I agree that a config option would make more convincing a solution ; unfortunately I'm swamped with work these days and unable to revise and resubmit. Please feel free to do so on your own or otherwise close.