mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
fix(HTTP Request Node): Fix prototype pollution vulnerability (#15463)
This commit is contained in:
@@ -4,6 +4,7 @@ import isPlainObject from 'lodash/isPlainObject';
|
||||
import set from 'lodash/set';
|
||||
import {
|
||||
deepCopy,
|
||||
setSafeObjectProperty,
|
||||
type ICredentialDataDecryptedObject,
|
||||
type IDataObject,
|
||||
type INodeExecutionData,
|
||||
@@ -48,7 +49,7 @@ function redact<T = unknown>(obj: T, secrets: string[]): T {
|
||||
return obj.map((item) => redact(item, secrets)) as T;
|
||||
} else if (isObject(obj)) {
|
||||
for (const [key, value] of Object.entries(obj)) {
|
||||
(obj as IDataObject)[key] = redact(value, secrets);
|
||||
setSafeObjectProperty(obj, key, redact(value, secrets));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user