Advisory Database
  • Advisories
  • Dependency Scanning
  1. golang
  2. ›
  3. gopkg.in/yaml.v2
  4. ›
  5. CVE-2021-4235

CVE-2021-4235: YAML Go package vulnerable to denial of service

December 28, 2022 (updated April 11, 2025)

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.

References

  • github.com/advisories/GHSA-r88r-gmrh-7j83
  • github.com/go-yaml/yaml
  • github.com/go-yaml/yaml/commit/bb4e33bf68bf89cad44d386192cbed201f35b241
  • github.com/go-yaml/yaml/pull/375
  • lists.debian.org/debian-lts-announce/2023/07/msg00001.html
  • nvd.nist.gov/vuln/detail/CVE-2021-4235
  • pkg.go.dev/vuln/GO-2021-0061

Code Behaviors & Features

Detect and mitigate CVE-2021-4235 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 2.2.3

Fixed versions

  • 2.2.3

Solution

Upgrade to version 2.2.3 or above.

Impact 5.5 MEDIUM

CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H

Learn more about CVSS

Source file

go/gopkg.in/yaml.v2/CVE-2021-4235.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:14:51 +0000.