diff --git a/backend/src/main/java/ddangkong/controller/room/RejoinCookieEncryptor.java b/backend/src/main/java/ddangkong/controller/room/RejoinCookieEncryptor.java index ba7da273..d7725cd6 100644 --- a/backend/src/main/java/ddangkong/controller/room/RejoinCookieEncryptor.java +++ b/backend/src/main/java/ddangkong/controller/room/RejoinCookieEncryptor.java @@ -18,7 +18,10 @@ public RejoinCookieEncryptor(EncryptionUtils encryptionUtils, @Value("${cookie.r public Cookie getEncodedCookie(Object value) { String encrypt = encryptionUtils.encrypt(String.valueOf(value)); - return new Cookie(rejoinKey, encrypt); + Cookie cookie = new Cookie(rejoinKey, encrypt); + cookie.setHttpOnly(true); + cookie.setSecure(true); + return cookie; } public Long getDecodedCookieValue(String cookieValue) {