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

Remember document URL after expired authentication #4466

Open
bjoernmartin opened this issue Jul 17, 2023 · 1 comment
Open

Remember document URL after expired authentication #4466

bjoernmartin opened this issue Jul 17, 2023 · 1 comment
Labels
status: blocked by upstream Problems with dependencies. Things we have little control over or that should be fixed at the source status: confirmed We have confirmed that the issue exists type: bug Something isn't working
Milestone

Comments

@bjoernmartin
Copy link

bjoernmartin commented Jul 17, 2023

Which part of the project should be enhanced?

Missing Auth Redirection Code Base

Is your enhancement request related to a problem? Please describe.

Whenever the authentication of Hedgedoc (auth via OAuth2 (Keycloak instance)) expires, Hedgedoc redirects to its base URL. When logging in again, the document visited / URL active before redirection is lost and the information about which document was viewed in that tab is lost.

Describe the solution you'd like

Whenever the authentication of Hedgedoc expires, Hedgedoc redirects to its base URL but remembers the original URL, e.g. via query parameter such as ?lastVisited=n0ZtF0-uR96LDAMpSPHqQg. When logging in again, the document visited is shown again.

Describe alternatives you've considered

Logging in and then using the browser's Back button to get back to the document that tab had open before.

Strange enough, sometimes even the browser history does not contain any information on that URL anymore. Possibly because JavaScript is used to rewrite the current URL instead of redirecting, preventing the browser from storing any history on this.

Additional context

  • Possibly specific to the OAuth2 authentication flow / implementation.
  • Reported for a self-hosted HedgeDoc 1.9.6 installation
    • According to Release Notes this issue was not fixed in 1.9.7 thru 1.9.9
@davidmehren davidmehren added the type: bug Something isn't working label Oct 7, 2023
@davidmehren davidmehren added this to the Version 1.x milestone Oct 7, 2023
@ErikMichelson
Copy link
Member

See #4483 for the state on this.

@ErikMichelson ErikMichelson added status: blocked by upstream Problems with dependencies. Things we have little control over or that should be fixed at the source status: confirmed We have confirmed that the issue exists labels Oct 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: blocked by upstream Problems with dependencies. Things we have little control over or that should be fixed at the source status: confirmed We have confirmed that the issue exists type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants