Open robertsarkozi opened 1 year ago
A possible solution could be the changes I made in a fork: https://github.com/robertsarkozi/rocket_auth/commit/94bb98cf19749aa71b29bfab5e93f13f9e300137
clear_expired()
in Users::is_auth()
to clear all expired sessionsnow()
)
login_for
method takes a Duration parameter, for how long the user should be logged in, after whose expiration I'm expecting the user to not be authorized anymore. I'm trying this with one minute.In
session/default/mod.rs
this sets the auth key for that amout of time, but it seems it doesn't have effect...User session keeps letting me make requests even after 1 minute has passed.
Shouldn't rocket_auth automatically invalidate the session after expiration?