withHttpOnlyCookie defaults to false

Closes gh-13659
This commit is contained in:
Josh Cummings
2023-08-28 16:58:28 -06:00
parent bbf2dd7091
commit a4d8c62ad7
2 changed files with 14 additions and 1 deletions

View File

@@ -178,7 +178,7 @@ public final class CookieCsrfTokenRepository implements CsrfTokenRepository {
*/
public static CookieCsrfTokenRepository withHttpOnlyFalse() {
CookieCsrfTokenRepository result = new CookieCsrfTokenRepository();
result.setCookieCustomizer((cookie) -> cookie.httpOnly(false));
result.cookieHttpOnly = false;
return result;
}