32
How to store user's access tokens/API keys without hashing them?
(lemmy.pe1uca.dev)
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Follow the wormhole through a path of communities !webdev@programming.dev
Oh I've only used JWTs with OIDC so I didn't thought about using them directly.
It could be a good solution since the user can generate them on their own and we can validate them with the correct information (secret or public key).
About the issue of long lived or not expiring JWT, maybe a custom restriction of valid tokens with lifespans of more than X amount of minutes are rejected?
Yeah, the token could be a valid one but we could say the payload is invalid for our API.