# CVE-2021-4235: Denial of service in gopkg.in/yaml.v2

- Severity: Medium 5.5 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.43%, higher than 39% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2021-04-14T20:04:52.000Z
- Modified: 2026-09-10T03:49:50.573Z
- Also known as: GHSA-r88r-gmrh-7j83, GO-2021-0061
- Related: CGA-8cfw-g9m8-h5q8, RHSA-2022:7398
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: Go

## Description

Due to unbounded alias chasing, a maliciously crafted YAML file can cause the system to consume significant system resources. If parsing user input, this may be used as a denial of service vector.

(As written by CVE List.)

## Affected

- gopkg.in/yaml.v2: before 2.2.3
- github.com/go-yaml/yaml: no versions given
- gopkg.in/yaml.v2 (Go): before 2.2.3
- github.com/go-yaml/yaml (Go): up to 2.1.0; all versions
- yaml_project yaml: before 2.2.3

## Every score

- CISA-ADP: CVSS:3.1 5.5 Medium `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- GitHub: CVSS:3.1 5.5 Medium `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- NVD: CVSS:3.1 5.5 Medium `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`

## References

- <https://github.com/go-yaml/yaml/pull/375> (exploit, fix, patch, third-party-advisory, web)
- <https://github.com/go-yaml/yaml/commit/bb4e33bf68bf89cad44d386192cbed201f35b241> (fix, patch, third-party-advisory, web)
- <https://pkg.go.dev/vuln/GO-2021-0061> (third-party-advisory, web)
- <https://lists.debian.org/debian-lts-announce/2023/07/msg00001.html> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-4235> (advisory)
- <https://github.com/go-yaml/yaml> (package)

## Sources

- CVE List: [CVE-2021-4235](https://www.cve.org/CVERecord?id=CVE-2021-4235), CVE Terms of Use, modified 2025-04-11
- GitHub Advisory Database: [GHSA-r88r-gmrh-7j83](https://github.com/advisories/GHSA-r88r-gmrh-7j83), CC-BY-4.0, modified 2026-09-10
- Go Vulnerability Database: [GO-2021-0061](https://pkg.go.dev/vuln/GO-2021-0061), CC-BY-4.0, modified 2026-02-04
- NVD: [CVE-2021-4235](https://nvd.nist.gov/vuln/detail/CVE-2021-4235), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-4235 · Whole record: https://cve.day/CVE-2021-4235.json · Rebuilt by cve.day 2026-11-25T22:58:08.017Z
