CVE-2022-38752: Denial of Service in snakeYAML before 1.32

org.yaml:snakeyaml Updated 02 Oct 2025

Summary

06/09/2022
Yes i
Moderate
6.5

CVE-2022-38752: snakeYAML before 1.32 vulnerable to Denial of Service due to Out-of-bounds Write. Affects org.yaml:snakeyaml versions < 1.32. Fixed in 1.32. How to fix ↓

Also tracked for

The same CVE-2022-38752 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

snakeYAML is a popular Java library used for parsing YAML files. It provides functionality to convert YAML data into Java objects and vice versa. The library is widely used in various applications and frameworks that require YAML processing. However, versions prior to 1.32 are vulnerable to a Denial of Service (DoS) attack due to an out-of-bounds write issue. This vulnerability can be exploited by an attacker to crash the parser by causing a stack overflow.

Vulnerability Detail

The vulnerability in snakeYAML arises when parsing untrusted YAML files. If the parser is running on user-supplied input, an attacker can provide malicious content that triggers a stack overflow, leading to a crash. This can result in a Denial of Service situation where the application becomes unresponsive or crashes, impacting its availability. The vulnerability is rated as moderate in severity with a CVSS score of 6.5.

How To Fix

Latest published version: 2.7 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.32

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, developers can implement input validation and sanitization measures to mitigate the risk of this vulnerability. By carefully validating and filtering user-supplied YAML input, the likelihood of triggering the stack overflow can be reduced. However, this workaround may not provide complete protection and upgrading to the fixed version is strongly recommended.

Conclusion

snakeYAML versions prior to 1.32 are vulnerable to a Denial of Service attack due to an out-of-bounds write issue. This vulnerability can be exploited by supplying malicious YAML content, causing the parser to crash. To mitigate this risk, it is crucial to upgrade to snakeYAML 1.32 or later. Developers should also consider implementing input validation and sanitization measures. For further assistance and support in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for org.yaml:snakeyaml →

Share this vulnerability

FAQ

snakeYAML is a Java library for parsing and generating YAML data. It is commonly used in applications and frameworks that require YAML processing.

The vulnerability allows an attacker to crash the snakeYAML parser by triggering a stack overflow. This can lead to a Denial of Service situation where the application becomes unresponsive or crashes.

To fix this vulnerability, upgrade snakeYAML to version 1.32 or later. This version includes a fix for the out-of-bounds write issue.

As a temporary workaround, developers can implement input validation and sanitization measures to reduce the risk of triggering the vulnerability. However, upgrading to the fixed version is strongly recommended.

The vulnerability is rated as moderate in severity with a CVSS score of 6.5.

Related vulnerabilities

Recent vulnerabilities recorded for org.yaml:snakeyaml.

How To Fix

Latest published version: 2.7 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.32

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback