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

Unhandled 401 Error "Bricks" App #45

Open
JonahKr opened this issue Oct 1, 2023 · 8 comments
Open

Unhandled 401 Error "Bricks" App #45

JonahKr opened this issue Oct 1, 2023 · 8 comments

Comments

@JonahKr
Copy link

JonahKr commented Oct 1, 2023

When changing your password via the webinterface the app tries to authenticate with the older credentials indefenitly.
There is no way to escape this loop other than reinstalling the app. Ideally one would be prompted with the login screen again.
markup_285 (2).png

@princelai
Copy link

Yes, the JWT key is set by default to 259200 (three days). The error is caused by the absence of an automatically issued JWT key if you don't log in for three days. You can try setting this value to 2592000, while also ensuring a login every month.

@kolaente
Copy link
Member

You can try setting this value to 2592000, while also ensuring a login every month.

Another option would be to use the frontend to login and then check the "remember me" checkbox.

@Benimautner
Copy link
Collaborator

You should be able to close messages like this by pressing the back button once. Then go to settings, click log out, and log in again. But yes, you're right, this shouldn't happen.

@Benimautner
Copy link
Collaborator

Closed due to inactivity. Open a new issue if you still need help.

@JonahKr
Copy link
Author

JonahKr commented Jan 5, 2024

The issue still persists. I don't think it is necessarily high priority but still.

@Benimautner
Copy link
Collaborator

I remember having the same issue some time ago. My problem was that I did not have a JWTSecret set, and so every time vikunja restarted it was rotated and I was logged out. Does this happen in the web interface as well?
What fixed it was adding this to my config.yml:

service:
  JWTSecret: <SECRET>

see https://vikunja.io/docs/config-options/#jwtsecret

@Benimautner
Copy link
Collaborator

After consulting with @kolaente I've expanded the app token refresh in the upcoming release to the level of the frontend. Every time you start the app and automatically every 12 hours the token should be refreshed, so it should never expire. I haven't extensively tried it myself but the refreshing on app launch definitely works, so please do let me know whether you still experience this with 0.1.4-beta.

@JonahKr
Copy link
Author

JonahKr commented Mar 3, 2024

The logout behaviour has definitely improved! Thanks a lot!

Still I think it would make sense to redirect the user to the login screen when the token is invalid for whatever reason. Then the user will be able to just login without having to navigate to the settings with the constant popup.

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

No branches or pull requests

4 participants