Updates
This commit is contained in:
@@ -69,6 +69,7 @@ function userAuth({ request, req, encryptionKey, encryptionSalt, level, database
|
||||
success: false,
|
||||
payload: null,
|
||||
msg: "Couldn't Decrypt cookie",
|
||||
cookieNames: keyNames,
|
||||
};
|
||||
}
|
||||
/**
|
||||
@@ -86,6 +87,7 @@ function userAuth({ request, req, encryptionKey, encryptionSalt, level, database
|
||||
success: false,
|
||||
payload: null,
|
||||
msg: "No CSRF_K in decrypted payload",
|
||||
cookieNames: keyNames,
|
||||
};
|
||||
}
|
||||
if (!(0, write_auth_files_1.checkAuthFile)(userObject.csrf_k)) {
|
||||
@@ -93,6 +95,7 @@ function userAuth({ request, req, encryptionKey, encryptionSalt, level, database
|
||||
success: false,
|
||||
payload: null,
|
||||
msg: "Auth file doesn't exist",
|
||||
cookieNames: keyNames,
|
||||
};
|
||||
}
|
||||
/**
|
||||
@@ -107,6 +110,7 @@ function userAuth({ request, req, encryptionKey, encryptionSalt, level, database
|
||||
success: false,
|
||||
payload: null,
|
||||
msg: "CSRF_K mismatch",
|
||||
cookieNames: keyNames,
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -117,6 +121,7 @@ function userAuth({ request, req, encryptionKey, encryptionSalt, level, database
|
||||
success: false,
|
||||
payload: null,
|
||||
msg: "Payload Creation Date is not a number",
|
||||
cookieNames: keyNames,
|
||||
};
|
||||
}
|
||||
const timeElapsed = Date.now() - payloadCreationDate;
|
||||
@@ -128,6 +133,7 @@ function userAuth({ request, req, encryptionKey, encryptionSalt, level, database
|
||||
success: false,
|
||||
payload: null,
|
||||
msg: "Session has expired",
|
||||
cookieNames: keyNames,
|
||||
};
|
||||
}
|
||||
/**
|
||||
|
||||
+2
-5
@@ -41,7 +41,6 @@ function sqlGenerator({ tableName, genObject, dbFullName }) {
|
||||
}
|
||||
}
|
||||
else if (Array.isArray(queryObj.value)) {
|
||||
/** @type {string[]} */
|
||||
const strArray = [];
|
||||
queryObj.value.forEach((val) => {
|
||||
const valueParsed = val;
|
||||
@@ -62,13 +61,11 @@ function sqlGenerator({ tableName, genObject, dbFullName }) {
|
||||
return str;
|
||||
}
|
||||
const sqlSearhString = queryKeys === null || queryKeys === void 0 ? void 0 : queryKeys.map((field) => {
|
||||
const queryObj =
|
||||
/** @type {import("../../../types").ServerQueryQueryObject} */ finalQuery === null || finalQuery === void 0 ? void 0 : finalQuery[field];
|
||||
const queryObj = finalQuery === null || finalQuery === void 0 ? void 0 : finalQuery[field];
|
||||
if (!queryObj)
|
||||
return;
|
||||
if (queryObj.__query) {
|
||||
const subQueryGroup =
|
||||
/** @type {import("../../../types").ServerQueryQueryObject}} */ queryObj.__query;
|
||||
const subQueryGroup = queryObj.__query;
|
||||
const subSearchKeys = Object.keys(subQueryGroup);
|
||||
const subSearchString = subSearchKeys.map((_field) => {
|
||||
const newSubQueryObj = subQueryGroup === null || subQueryGroup === void 0 ? void 0 : subQueryGroup[_field];
|
||||
|
||||
Vendored
+3
@@ -55,6 +55,9 @@ export declare const TextFieldTypesArray: readonly [{
|
||||
}, {
|
||||
readonly title: "Javascript";
|
||||
readonly value: "javascript";
|
||||
}, {
|
||||
readonly title: "Shell";
|
||||
readonly value: "shell";
|
||||
}];
|
||||
export type DSQL_FieldSchemaType = {
|
||||
fieldName?: string;
|
||||
|
||||
Vendored
+1
@@ -9,6 +9,7 @@ exports.TextFieldTypesArray = [
|
||||
{ title: "HTML", value: "html" },
|
||||
{ title: "CSS", value: "css" },
|
||||
{ title: "Javascript", value: "javascript" },
|
||||
{ title: "Shell", value: "shell" },
|
||||
];
|
||||
exports.ServerQueryOperators = ["AND", "OR"];
|
||||
exports.ServerQueryEqualities = ["EQUAL", "LIKE", "NOT EQUAL"];
|
||||
|
||||
Reference in New Issue
Block a user