diff --git a/library/agent/hooks/onInspectionInterceptorResult.ts b/library/agent/hooks/onInspectionInterceptorResult.ts index 80123cd1..1e64fb2f 100644 --- a/library/agent/hooks/onInspectionInterceptorResult.ts +++ b/library/agent/hooks/onInspectionInterceptorResult.ts @@ -42,7 +42,7 @@ export function onInspectionInterceptorResult( source: result.source, blocked: agent.shouldBlock(), stack: cleanupStackTrace(new Error().stack!, libraryRoot), - path: result.pathToPayload, + paths: result.pathsToPayload, metadata: result.metadata, request: context, payload: result.payload, @@ -50,7 +50,7 @@ export function onInspectionInterceptorResult( if (agent.shouldBlock()) { throw new Error( - `Zen has blocked ${attackKindHumanName(result.kind)}: ${result.operation}(...) originating from ${result.source}${escapeHTML(result.pathToPayload)}` + `Zen has blocked ${attackKindHumanName(result.kind)}: ${result.operation}(...) originating from ${result.source}${escapeHTML((result.pathsToPayload || []).join())}` ); } } diff --git a/library/sinks/Prisma.ts b/library/sinks/Prisma.ts index 29105777..94a773af 100644 --- a/library/sinks/Prisma.ts +++ b/library/sinks/Prisma.ts @@ -148,7 +148,7 @@ export class Prisma implements Wrapper { operation: `prisma.${operation}`, kind: "nosql_injection", source: result.source, - pathToPayload: result.pathToPayload, + pathsToPayload: result.pathsToPayload, metadata: { collection: collection, operation: operation,