summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Frédéric Guillot <fred@miniflux.net> 2020-08-10 18:51:40 -0700
committerGravatar Frédéric Guillot <fred@miniflux.net> 2020-08-10 18:51:40 -0700
commitc1e378327239b54c9949aec0946759bae4b6018a (patch)
treeb20f67d546f1a4265c94a6e5358ee9043005f419
parenteaf1fc896fbbd87bbea1687aa665fc054ee2f5a0 (diff)
downloadv2-c1e378327239b54c9949aec0946759bae4b6018a.tar.gz
v2-c1e378327239b54c9949aec0946759bae4b6018a.tar.zst
v2-c1e378327239b54c9949aec0946759bae4b6018a.zip
Revert "Set SameSite cookie attribute to Strict"
This reverts commit 5ac55518abe87ff871942c02c0cf0c536c6035d8. Google Authentication doesn't work when Cookies are using strict mode.
-rw-r--r--http/cookie/cookie.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/http/cookie/cookie.go b/http/cookie/cookie.go
index 74f95314..8874c412 100644
--- a/http/cookie/cookie.go
+++ b/http/cookie/cookie.go
@@ -27,7 +27,7 @@ func New(name, value string, isHTTPS bool, path string) *http.Cookie {
Secure: isHTTPS,
HttpOnly: true,
Expires: time.Now().Add(cookieDuration * 24 * time.Hour),
- SameSite: http.SameSiteStrictMode,
+ SameSite: http.SameSiteLaxMode,
}
}
@@ -41,7 +41,7 @@ func Expired(name string, isHTTPS bool, path string) *http.Cookie {
HttpOnly: true,
MaxAge: -1,
Expires: time.Date(1970, 1, 1, 0, 0, 0, 0, time.UTC),
- SameSite: http.SameSiteStrictMode,
+ SameSite: http.SameSiteLaxMode,
}
}