mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 17:46:45 +00:00
fix(core): set JWT authentication token sameSite policy to lax (#4425)
set authentication token sameSite policy to lax
This commit is contained in:
committed by
GitHub
parent
5745027cee
commit
1f4eaeb3ae
@@ -63,5 +63,9 @@ export async function resolveJwt(token: string): Promise<User> {
|
||||
|
||||
export async function issueCookie(res: Response, user: User): Promise<void> {
|
||||
const userData = issueJWT(user);
|
||||
res.cookie(AUTH_COOKIE_NAME, userData.token, { maxAge: userData.expiresIn, httpOnly: true });
|
||||
res.cookie(AUTH_COOKIE_NAME, userData.token, {
|
||||
maxAge: userData.expiresIn,
|
||||
httpOnly: true,
|
||||
sameSite: 'lax',
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user