Open JeGr opened 2 weeks ago
Sorry for the rate limit, that's actually a little unfortunate.
There is no auto-cleanup job. Tokens are deleted upon request (e.g., during logout), and just like other API tokens, login tokens otherwise hang around, and depending on circumstances (e.g., time) might become invalid.
The leftover tokens are a symptom of not logging out of the session. While you can say that's fine in your use case, we also think the leftover tokens are not a big problem.
That said, perhaps it would indeed make sense to have them cleaned up. The question is how to do this cheaply, as the validity calculation is currently not done in the database, but in the backend application. Perhaps an alternative solution would be to clean up tokens whenever the list is viewed, so that cleanup is on-demand only (cheap) but still transparent to the user. @nils-wisiol ?
Just a few comments/ideas :)
of not logging out of the session
I'd argue that people do that more often than actually hitting the logout. For me, it's almost default, that my services do log me out automatically either if I close my browser (as the cookies get cleaned up) or after a timeout. As I'm often working mobile or at a laptop, that gets closed in a heartbeat if there's other important stuff happening, I'd guess that most users have accumulated quite a collection of auto-disabled-logout tokens.
Normally that wouldn't be a problem, but as my actual tokens are quite old and often at the end of the list, I have to scroll to the bottom to see them or look at the "disabled" column to see which tokens are actual working API tokens and which are login tokens only.
So I'd like to throw a few points out there, perhaps you find them useful: :)
Thanks for a great service!
Cheers \jens
Hi,
logged into my desec account and created a new token for another service to set up DNS entries. That's where I found I had around 30 disabled login tokens still in my account that weren't cleaned up which dated back to over a year. Manually cleaning them up I ran into the rate limit -.- so had to come back later to finish it.
Is there no auto-cleanup of auto-disabled login tokens or is the job not working correctly? I don't see why I'd need an auto-created login token even 2-4 weeks later so was quite surprised there was stuff over a year ago?
Cheers \jens