CVEfocus › CVE database › CVE-2021-4235

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

CVSS 5.5 MediumEPSS 0.4% (higher than 29% of CVEs)Published 2022-12-27Updated 2025-04-11Assigner: Go

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.

What to do

Fixed builds are available from Debian, Go, Ubuntu: see the table below for the fixed version per release.

Go, Ubuntu have not shipped a fix for every release yet.

Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.

curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \
  -H "Content-Type: text/plain" --data-binary @inventory.txt

Vendor status at a glance

5Fixed
9Fix pending
4Under investigation
8Will not fix
10Not affected

Status by vendor and release

From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.

ReleasePackageStatusFixed versionAdvisory
Ubuntu 26.10golang-github-coreos-discovery-etcd-ioFix pendingUBUNTU-CVE-2021-4235
Ubuntu 26.10webhookFix pendingUBUNTU-CVE-2021-4235
Ubuntu 26.04golang-github-coreos-discovery-etcd-ioFix pendingUBUNTU-CVE-2021-4235
Ubuntu 26.04golang-gopkg-yaml.v3Not affected
vulnerable_code_not_present
Ubuntu 26.04golang-yaml.v2Not affected
vulnerable_code_not_present
Ubuntu 26.04singularity-containerUnder investigationUBUNTU-CVE-2021-4235
Ubuntu 26.04webhookUnder investigationUBUNTU-CVE-2021-4235
Ubuntu 25.10golang-github-coreos-discovery-etcd-ioWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
UBUNTU-CVE-2021-4235
Ubuntu 25.10golang-gopkg-yaml.v3Not affected
vulnerable_code_not_present
Ubuntu 25.10golang-yaml.v2Not affected
vulnerable_code_not_present
Ubuntu 25.10singularity-containerWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
UBUNTU-CVE-2021-4235
Ubuntu 25.10webhookWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
UBUNTU-CVE-2021-4235
Ubuntu 24.04golang-github-coreos-discovery-etcd-ioFix pendingUBUNTU-CVE-2021-4235
Ubuntu 24.04golang-gopkg-yaml.v3Not affected
vulnerable_code_not_present
Ubuntu 24.04golang-yaml.v2Not affected
vulnerable_code_not_present
Ubuntu 24.04kubernetesNot affected
vulnerable_code_not_present
Ubuntu 24.04singularity-containerFix pendingUBUNTU-CVE-2021-4235
Ubuntu 24.04webhookUnder investigationUBUNTU-CVE-2021-4235
Ubuntu 22.04golang-github-coreos-discovery-etcd-ioFix pendingUBUNTU-CVE-2021-4235
Ubuntu 22.04golang-gopkg-yaml.v3Not affected
vulnerable_code_not_present
Ubuntu 22.04golang-yaml.v2Not affected
vulnerable_code_not_present
Ubuntu 22.04kubernetesNot affected
vulnerable_code_not_present
Ubuntu 22.04webhookUnder investigationUBUNTU-CVE-2021-4235
Ubuntu 20.04golang-github-coreos-discovery-etcd-ioWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
UBUNTU-CVE-2021-4235
Ubuntu 20.04golang-yaml.v2Fixed2.2.2-1ubuntu0.1UBUNTU-CVE-2021-4235
Ubuntu 20.04kubernetesWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
Ubuntu 20.04webhookWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
UBUNTU-CVE-2021-4235
Ubuntu 18.04golang-yaml.v2Fix pending0.0+git20170407.0.cd8b52f-1ubuntu2+esm1 (Ubuntu Pro)UBUNTU-CVE-2021-4235
Ubuntu 18.04singularity-containerFix pendingUBUNTU-CVE-2021-4235
Ubuntu 18.04webhookWill not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
UBUNTU-CVE-2021-4235
Ubuntu 16.04golang-yaml.v2Will not fix
kubernates is in fact a kubernetes installer that calls snap, not the package it self. golang-github-coreos-discovery-etcd-io is potentially affected due to…
0.0+git20160301.0.a83829b-1ubuntu0.1~esm1 (Ubuntu Pro)UBUNTU-CVE-2021-4235
Debian 14golang-yaml.v2Fixed2.2.8-1DEBIAN-CVE-2021-4235
Debian 13golang-yaml.v2Fixed2.2.8-1DEBIAN-CVE-2021-4235
Debian 12golang-yaml.v2Fixed2.2.8-1DEBIAN-CVE-2021-4235
Go librarygithub.com/go-yaml/yamlFix pendingGO-2021-0061
Go librarygopkg.in/yaml.v2Fixed2.2.3GHSA-r88r-gmrh-7j83

What the vendor says

As published in the CVE record by Go, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.

References

About this page

Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.