CVE-2025-64718: js-yaml has prototype pollution in merge (<<)
Impact
In js-yaml 4.1.0, 4.0.0, and 3.14.1 and below, it's possible for an attacker to modify the prototype of the result of a parsed yaml document via prototype pollution (proto). All users who parse untrusted yaml documents may be impacted.
Patches
Problem is patched in js-yaml 4.1.1 and 3.14.2.
Workarounds
You can protect against this kind of attack on the server by using node --disable-proto=delete or deno (in Deno, pollution protection is on by default).
References
https://cheatsheetseries.owasp.org/cheatsheets/PrototypePollutionPreventionCheatSheet.html
Other sources
js-yaml is a JavaScript YAML parser and dumper. In js-yaml before 4.1.1 and 3.14.2, it's possible for an attacker to modify the prototype of the result of a parsed yaml document via prototype pollution (proto). All users who parse untrusted yaml documents may be impacted. The problem is patched in js-yaml 4.1.1 and 3.14.2. Users can protect against this kind of attack on the server by using node --disable-proto=delete or deno (in Deno, pollution protection is on by default).
— MITRE
Affected Software
Remediation
Event History
Frequently Asked Questions
What is the severity of CVE-2025-64718?
CVE-2025-64718 has been classified as a moderate severity vulnerability.
How do I fix CVE-2025-64718?
To fix CVE-2025-64718, upgrade js-yaml to version 4.1.1 or later.
Who is affected by CVE-2025-64718?
Any users of js-yaml version 4.1.0 or below who parse untrusted YAML documents are potentially affected.
What type of vulnerability is CVE-2025-64718?
CVE-2025-64718 is a prototype pollution vulnerability that allows modification of the result of a parsed YAML document.
What is the impact of CVE-2025-64718?
The impact of CVE-2025-64718 can lead to unexpected behavior or security issues in applications that use js-yaml for parsing YAML.