fix(api): CSRF-token should not be httpOnly (#55365)

This commit is contained in:
Oliver Eyton-Williams
2024-07-01 21:54:01 +02:00
committed by GitHub
parent 464dbf6a28
commit 669b4908b1
+4 -1
View File
@@ -140,7 +140,10 @@ export const build = async (
const token = reply.generateCsrf();
void reply.setCookie('csrf_token', token, {
sameSite: 'strict',
signed: false
signed: false,
// it needs to be read by the client, so that it can be sent in the
// header of the next request:
httpOnly: false
});
}
done();