mirror of
https://github.com/simple-login/app.git
synced 2025-09-10 08:34:32 +08:00
Set session to lax
This commit is contained in:
parent
747dfc04bb
commit
e0d4ee9f8c
1 changed files with 2 additions and 0 deletions
|
@ -87,6 +87,7 @@ class RedisSessionStore(SessionInterface):
|
||||||
httponly = self.get_cookie_httponly(app)
|
httponly = self.get_cookie_httponly(app)
|
||||||
secure = self.get_cookie_secure(app)
|
secure = self.get_cookie_secure(app)
|
||||||
expires = self.get_expiration_time(app, session)
|
expires = self.get_expiration_time(app, session)
|
||||||
|
samesite = self.get_cookie_samesite(app)
|
||||||
val = pickle.dumps(dict(session))
|
val = pickle.dumps(dict(session))
|
||||||
ttl = int(app.permanent_session_lifetime.total_seconds())
|
ttl = int(app.permanent_session_lifetime.total_seconds())
|
||||||
# Only 5 minutes for non-authenticated sessions.
|
# Only 5 minutes for non-authenticated sessions.
|
||||||
|
@ -109,6 +110,7 @@ class RedisSessionStore(SessionInterface):
|
||||||
domain=domain,
|
domain=domain,
|
||||||
path=path,
|
path=path,
|
||||||
secure=secure,
|
secure=secure,
|
||||||
|
samesite=samesite,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue