File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ func SetJWTCookie(c echo.Context, jwt service.JWT) error {
56
56
cookie .Value = jwt .Token
57
57
// cookie.HttpOnly = true // due the short expiration time it is not needed to be http only
58
58
cookie .Expires = jwt .ExpAt // we want the cookie to expire at the same time as the token
59
- cookie .SameSite = http .SameSiteLaxMode
59
+ cookie .SameSite = http .SameSiteNoneMode
60
60
cookie .Path = "/" // Send cookie in every sub path request
61
61
cookie .Secure = ! IsLocalEnv () // in production allow https only
62
62
c .SetCookie (cookie )
@@ -70,7 +70,7 @@ func SetRefreshTokenCookie(c echo.Context, refresh service.RefreshTokenResponse)
70
70
cookie .Value = refresh .Token
71
71
cookie .HttpOnly = true
72
72
cookie .Expires = refresh .ExpAt // we want the cookie to expire at the same time as the token
73
- cookie .SameSite = http .SameSiteLaxMode
73
+ cookie .SameSite = http .SameSiteNoneMode
74
74
cookie .Path = "/login/" // Send cookie only in /login path request
75
75
cookie .Secure = ! IsLocalEnv () // in production allow https only
76
76
c .SetCookie (cookie )
@@ -107,7 +107,7 @@ func DeleteAuthCookies(c echo.Context) error {
107
107
cookie .Name = "refresh_token"
108
108
cookie .Value = ""
109
109
cookie .Expires = time .Now ()
110
- cookie .SameSite = http .SameSiteLaxMode
110
+ cookie .SameSite = http .SameSiteNoneMode
111
111
cookie .Path = "/login/" // Send cookie only in refresh path request
112
112
cookie .Secure = ! IsLocalEnv ()
113
113
c .SetCookie (cookie )
You can’t perform that action at this time.
0 commit comments