feat: Ability to toggle cookies to work in HTTP (#4194)
* feat: added new env variable * feat: made http secure cookie conditional * chore: added comments to env files * chore: changed target of hopp-old-backend service to prod
This commit is contained in:
@@ -52,13 +52,13 @@ export const authCookieHandler = (
|
||||
|
||||
res.cookie(AuthTokenType.ACCESS_TOKEN, authTokens.access_token, {
|
||||
httpOnly: true,
|
||||
secure: true,
|
||||
secure: configService.get('ALLOW_SECURE_COOKIES') === 'true',
|
||||
sameSite: 'lax',
|
||||
maxAge: accessTokenValidity,
|
||||
});
|
||||
res.cookie(AuthTokenType.REFRESH_TOKEN, authTokens.refresh_token, {
|
||||
httpOnly: true,
|
||||
secure: true,
|
||||
secure: configService.get('ALLOW_SECURE_COOKIES') === 'true',
|
||||
sameSite: 'lax',
|
||||
maxAge: refreshTokenValidity,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user