mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 09:34:57 +08:00
enhance(session): increase default cookie ttl to 60 days
This commit is contained in:
@@ -30,7 +30,7 @@ func Session(secret string) gin.HandlerFunc {
|
||||
|
||||
// Also set Secure: true if using SSL, you should though
|
||||
// TODO:same-site policy
|
||||
Store.Options(sessions.Options{HttpOnly: true, MaxAge: 7 * 86400, Path: "/"})
|
||||
Store.Options(sessions.Options{HttpOnly: true, MaxAge: 60 * 86400, Path: "/"})
|
||||
return sessions.Sessions("cloudreve-session", Store)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user