Vulnerabilities |
2 via 2 paths |
|---|---|
Dependencies |
52 |
Source |
GitHub |
Find, fix and prevent vulnerabilities in your code.
high severity
new
- Vulnerable module: js-yaml
- Introduced through: swagger-parser@8.0.4
Detailed paths
-
Introduced through: @naturacosmeticos/api-linter@natura-cosmeticos/api-linter › swagger-parser@8.0.4 › json-schema-ref-parser@7.1.4 › js-yaml@3.15.0Remediation: Upgrade to swagger-parser@9.0.0.
Overview
js-yaml is a human-friendly data serialization language.
Affected versions of this package are vulnerable to Inefficient Algorithmic Complexity in the readFlowCollection function of parser.ts, which reaches exponential time when a flow sequence entry turns out to be a key: value pair and the parser rewinds to parse that entry a second time as the key. An attacker can exhaust CPU and block the Node event loop by supplying a small YAML document, under 200 bytes, with deeply nested flow sequences of key: value entries, since the re-parsing makes the work grow as O(2^n) in nesting depth. Exploitation occurs under the default configuration when the application parses untrusted YAML with load() or loadAll(), and needs no special schema, anchors, aliases, or merge keys.
Remediation
Upgrade js-yaml to version 5.2.2 or higher.
References
medium severity
- Vulnerable module: js-yaml
- Introduced through: swagger-parser@8.0.4
Detailed paths
-
Introduced through: @naturacosmeticos/api-linter@natura-cosmeticos/api-linter › swagger-parser@8.0.4 › json-schema-ref-parser@7.1.4 › js-yaml@3.15.0Remediation: Upgrade to swagger-parser@9.0.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.