Re:Loginsrv: JWT login microservice with back ends like OAut...
by magicalhippo on Saturday May 23, 2020 @10:29PM
(#23288594)
> in practice i have seen access tokens with ttl of a few hours
The JWT tokens we get for m2m from Maskinporten[1] have a TTL of a couple of minutes.
No refresh tokens though, I guess they figure it doesn't make much difference since the "user" is a machine so no hassle just sending a full request again.
[1]: https://difi.github.io/felleslosninger/maskinporten_protocol...
Re:Loginsrv: JWT login microservice with back ends like OAut...
by bhl on Saturday May 23, 2020 @10:09PM
(#23288487)
> the revoked set is smaller than the full set of active tokens so maybe that is a win
Yeah, it seems to me the difference between having a revocation / blacklist and a non-JWT based sessions isn't the number of queries to a redis cache, since each request to the resource server will result in a check first. It's the in-memory size of the cache.
I think that clears up my question about the benefits of using JWT. Thanks! :)
that feels like a weird place to be in with server side state for stuff that is supposed to be stateless. i guess the revoked set is smaller than the full set of active tokens so maybe that is a win? curious if anyone has experience with this.