fix(API): validate excecutions and workflow filter parameters (#4424)

* typeorm queries with AND for filter, schema validation
* validate filters
* replace json.parse with jsonParse()
* limited fields further
* limited workflow fields further
* removes date filter fields and fix waitTill filter
* simplified filter name arrays
This commit is contained in:
Michael Auerswald
2022-10-26 13:30:35 +02:00
committed by GitHub
parent 1f610b90f6
commit dd3c59677b
3 changed files with 210 additions and 85 deletions

View File

@@ -597,6 +597,7 @@ export function whereClause({
/**
* Get the IDs of the workflows that have been shared with the user.
* Returns all IDs if user is global owner (see `whereClause`)
*/
export async function getSharedWorkflowIds(user: User): Promise<number[]> {
const sharedWorkflows = await Db.collections.SharedWorkflow.find({