jamesjmeyer210 / simple-auth

0 stars 0 forks source link

Implement Refresh Tokens #27

Closed jamesjmeyer210 closed 7 months ago

jamesjmeyer210 commented 7 months ago

The refresh token will have the following content:

These values will be serialized to json, then hashed against the signing key, and finally base64 encoded so that altogether it should look like:

base64(H("{"id":"...","time":"..."}"))

This way, the server will be able to validate the refresh tokens without needed any state beyond the associated jwt.