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

Unlink and login link are the same so user can get unregistered on login #307

Closed
vwbusguy opened this issue Aug 2, 2024 · 1 comment · Fixed by #336
Closed

Unlink and login link are the same so user can get unregistered on login #307

vwbusguy opened this issue Aug 2, 2024 · 1 comment · Fixed by #336
Labels
bug Something isn't working enhancement New feature or request

Comments

@vwbusguy
Copy link

vwbusguy commented Aug 2, 2024

I noticed that the login link and the link to unlink an OIDC are the same (/oauth/gitea in this case), so it seems that when the login is linked to from elsewhere that it is treated as an unlink instead of a login.

I setup OIDC auth through Forgejo and added a Gist link the the navbar. To make things easier on users who are already logged into forgejo to not have to click a button to login to opengist, I tried to set the link to the login like https://opengist-url/oauth/gitea, but it is redirecting to the settings page with a message that the Gitea account has been unlinked. This is a benign message, since OIDC is the only login method, but also not the expected landing page, so for now I've reverted to users having to click the login button to access gists when coming from the git forge.

This could be fixed by either only triggering the unlink when the referrer is the settings page or (probably better) changing the unlink endpoint to be distinct from the login endpoint.

@thomiceli thomiceli added bug Something isn't working enhancement New feature or request labels Aug 28, 2024
@thomiceli thomiceli moved this to Backlog in Opengist Sep 10, 2024
@thomiceli thomiceli moved this from Backlog to In progress in Opengist Sep 20, 2024
@github-project-automation github-project-automation bot moved this from In progress to Done in Opengist Sep 22, 2024
@vwbusguy
Copy link
Author

Many thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants