Skip to content

Commit

Permalink
all cookies sameSite as Strict for pkce
Browse files Browse the repository at this point in the history
  • Loading branch information
SiCoe committed Sep 25, 2023
1 parent f4c0e44 commit 6fc36a2
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions authn/pkce.index.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ function mainProcess(event, context, callback) {
path: '/',
httpOnly: true,
secure: true,
sameSite: 'strict',
maxAge: parseInt(config.SESSION_DURATION)
})
},
Expand Down Expand Up @@ -328,14 +329,16 @@ function redirect(request, headers, callback) {
"key": "Set-Cookie",
"value" : cookie.serialize('NONCE', n[1], {
path: '/',
httpOnly: true
httpOnly: true,
sameSite: 'strict'
})
},
{
"key": "Set-Cookie",
"value" : cookie.serialize('CV', challenge[0], {
path: '/',
httpOnly: true
httpOnly: true,
sameSite: 'strict'
})
}
],
Expand Down

0 comments on commit 6fc36a2

Please sign in to comment.