Skip to content

Commit

Permalink
CB-4596 fix http cookies (#2363)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-skoblikov authored Feb 6, 2024
1 parent d96e0b8 commit 0c03d20
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -183,10 +183,12 @@ public static void addResponseCookie(HttpServletRequest request, HttpServletResp

if (sameSite != null) {
if (!request.isSecure()) {
log.debug("Attempt to set Cookie `" + cookieName + "` with `SameSite=None` failed, it require a secure context/HTTPS");
log.debug("Attempt to set Cookie `" + cookieName + "` with `SameSite=" + sameSite + "` failed, it " +
"require a secure context/HTTPS");
} else {
sessionCookie.setSecure(true);
path = path.concat("; SameSite=" + sameSite);
}
sessionCookie.setSecure(true);
path = path.concat("; SameSite=" + sameSite);
}

sessionCookie.setPath(path);
Expand Down

0 comments on commit 0c03d20

Please sign in to comment.