updates
This commit is contained in:
parent
1c690339d1
commit
b257d71ae3
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "datasquirel",
|
"name": "datasquirel",
|
||||||
"version": "1.1.1",
|
"version": "1.1.2",
|
||||||
"description": "Cloud-based SQL data management tool",
|
"description": "Cloud-based SQL data management tool",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
@ -11,8 +11,10 @@ module.exports = function ({ request, response }) {
|
|||||||
* @description Check Encryption Keys
|
* @description Check Encryption Keys
|
||||||
*/
|
*/
|
||||||
try {
|
try {
|
||||||
const authKeyName = request.cookies.filter((cookie) => cookie.match(/datasquirel_.*_auth_key/))[0];
|
const cookiesKeys = Object.keys(request.cookies);
|
||||||
const csrfName = request.cookies.filter((cookie) => cookie.match(/datasquirel_.*_csrf/))[0];
|
|
||||||
|
const authKeyName = cookiesKeys.filter((cookieKey) => cookieKey.match(/datasquirel_.*_auth_key/))[0];
|
||||||
|
const csrfName = cookiesKeys.filter((cookieKey) => cookieKey.match(/datasquirel_.*_csrf/))[0];
|
||||||
|
|
||||||
response.setHeader("Set-Cookie", [`${authKeyName}=null;samesite=strict;path=/;HttpOnly=true;Secure=true`, `${csrfName}=null;samesite=strict;path=/;HttpOnly=true`, `dsqluid=null;samesite=strict;path=/;HttpOnly=true`]);
|
response.setHeader("Set-Cookie", [`${authKeyName}=null;samesite=strict;path=/;HttpOnly=true;Secure=true`, `${csrfName}=null;samesite=strict;path=/;HttpOnly=true`, `dsqluid=null;samesite=strict;path=/;HttpOnly=true`]);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user