CVEfocus › CVE database › CVE-2021-27918

CVE-2021-27918

CVSS 7.5 HighEPSS 2.5% (higher than 85% of CVEs)Published 2021-03-10Updated 2024-08-03Assigner: mitre

encoding/xml in Go before 1.15.9 and 1.16.x before 1.16.1 has an infinite loop if a custom TokenReader (for xml.NewTokenDecoder) returns EOF in the middle of an element. This can occur in the Decode, DecodeElement, or Skip method.

What to do

Fixed builds are available from Alpine, Go, Red Hat, Rocky Linux: see the table below for the fixed version per release.

Ubuntu has 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

25Fixed
13Fix pending
44Will not fix
101Not 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 22.04golang-1.13Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 20.04golang-1.13Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 20.04golang-1.14Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 18.04golang-1.10Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 18.04golang-1.13Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 18.04golang-1.8Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 18.04golang-1.9Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 16.04golang-1.10Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 16.04golang-1.13Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 16.04golang-1.6Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 14.04golangFix pending
Ubuntu 14.04golang-1.10Fix pendingUBUNTU-CVE-2021-27918
Ubuntu 14.04golang-1.6Fix pending
Red Hat Enterprise Linux 9buildahNot affected
Red Hat Enterprise Linux 9buildah-testsNot affected
Red Hat Enterprise Linux 9cppNot affected
Red Hat Enterprise Linux 9gccNot affected
Red Hat Enterprise Linux 9gcc-c++Not affected
Red Hat Enterprise Linux 9gcc-gfortranNot affected
Red Hat Enterprise Linux 9gcc-offload-nvptxNot affected
Red Hat Enterprise Linux 9gcc-plugin-annobinNot affected
Red Hat Enterprise Linux 9gcc-plugin-develNot affected
Red Hat Enterprise Linux 9go-toolsetNot affected
Red Hat Enterprise Linux 9golangNot affected
Red Hat Enterprise Linux 9golang-binNot affected
Red Hat Enterprise Linux 9golang-docsNot affected
Red Hat Enterprise Linux 9golang-miscNot affected
Red Hat Enterprise Linux 9golang-raceNot affected
Red Hat Enterprise Linux 9golang-srcNot affected
Red Hat Enterprise Linux 9golang-testsNot affected
Red Hat Enterprise Linux 9libasanNot affected
Red Hat Enterprise Linux 9libatomicNot affected
Red Hat Enterprise Linux 9libgccNot affected
Red Hat Enterprise Linux 9libgccjitNot affected
Red Hat Enterprise Linux 9libgccjit-develNot affected
Red Hat Enterprise Linux 9libgfortranNot affected
Red Hat Enterprise Linux 9libgompNot affected
Red Hat Enterprise Linux 9libgomp-offload-nvptxNot affected
Red Hat Enterprise Linux 9libitmNot affected
Red Hat Enterprise Linux 9libitm-develNot affected
Red Hat Enterprise Linux 9liblsanNot affected
Red Hat Enterprise Linux 9libquadmathNot affected
Red Hat Enterprise Linux 9libquadmath-develNot affected
Red Hat Enterprise Linux 9libstdc++Not affected
Red Hat Enterprise Linux 9libstdc++-develNot affected
Red Hat Enterprise Linux 9libstdc++-docsNot affected
Red Hat Enterprise Linux 9libstdc++-staticNot affected
Red Hat Enterprise Linux 9libtsanNot affected
Red Hat Enterprise Linux 9libubsanNot affected
Red Hat Enterprise Linux 8buildahNot affected
Red Hat Enterprise Linux 8buildah-testsNot affected
Red Hat Enterprise Linux 8cppNot affected
Red Hat Enterprise Linux 8delveFixed0:1.5.0-2.module+el8.4.0+8864+58b0fcdbRHSA-2021:3076
Red Hat Enterprise Linux 8gccNot affected
Red Hat Enterprise Linux 8gcc-c++Not affected
Red Hat Enterprise Linux 8gcc-gdb-pluginNot affected
Red Hat Enterprise Linux 8gcc-gfortranNot affected
Red Hat Enterprise Linux 8gcc-offload-nvptxNot affected
Red Hat Enterprise Linux 8gcc-plugin-annobinNot affected
Red Hat Enterprise Linux 8gcc-plugin-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-gccNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-gcc-c++Not affected
Red Hat Enterprise Linux 8gcc-toolset-10-gcc-gdb-pluginNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-gcc-gfortranNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-gcc-plugin-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libasan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libatomic-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libitm-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-liblsan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libquadmath-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libstdc++-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libstdc++-docsNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libtsan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-10-libubsan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-gccNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-gcc-c++Not affected
Red Hat Enterprise Linux 8gcc-toolset-9-gcc-gdb-pluginNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-gcc-gfortranNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-gcc-plugin-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libasan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libatomic-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libitm-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-liblsan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libquadmath-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libstdc++-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libstdc++-docsNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libtsan-develNot affected
Red Hat Enterprise Linux 8gcc-toolset-9-libubsan-develNot affected
Red Hat Enterprise Linux 8go-toolsetFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golangFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golang-binFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golang-docsFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golang-miscFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golang-raceFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golang-srcFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8golang-testsFixed0:1.15.14-1.module+el8.4.0+11833+614b07b8RHSA-2021:3076
Red Hat Enterprise Linux 8libasanNot affected
Red Hat Enterprise Linux 8libasan6Not affected
Red Hat Enterprise Linux 8libatomicNot affected
Red Hat Enterprise Linux 8libatomic-staticNot affected
Red Hat Enterprise Linux 8libgccNot affected
Red Hat Enterprise Linux 8libgfortranNot affected
Red Hat Enterprise Linux 8libgfortran-staticNot affected
Red Hat Enterprise Linux 8libgompNot affected
Red Hat Enterprise Linux 8libgomp-offload-nvptxNot affected
Red Hat Enterprise Linux 8libitmNot affected
Red Hat Enterprise Linux 8libitm-develNot affected
Red Hat Enterprise Linux 8liblsanNot affected
Red Hat Enterprise Linux 8libquadmathNot affected
Red Hat Enterprise Linux 8libquadmath-develNot affected
Red Hat Enterprise Linux 8libquadmath-staticNot affected
Red Hat Enterprise Linux 8libstdc++Not affected
Red Hat Enterprise Linux 8libstdc++-develNot affected
Red Hat Enterprise Linux 8libstdc++-docsNot affected
Red Hat Enterprise Linux 8libstdc++-staticNot affected
Red Hat Enterprise Linux 8libtsanNot affected
Red Hat Enterprise Linux 8libubsanNot affected
Red Hat Enterprise Linux 7buildahWill not fix
Out of support scope
Red Hat Enterprise Linux 7cppWill not fix
Out of support scope
Red Hat Enterprise Linux 7gccWill not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-c++Will not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-gfortranWill not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-gnatWill not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-goWill not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-objcWill not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-objc++Will not fix
Out of support scope
Red Hat Enterprise Linux 7gcc-plugin-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7golangNot affected
Red Hat Enterprise Linux 7golang-binNot affected
Red Hat Enterprise Linux 7golang-docsNot affected
Red Hat Enterprise Linux 7golang-miscNot affected
Red Hat Enterprise Linux 7golang-srcNot affected
Red Hat Enterprise Linux 7golang-testsNot affected
Red Hat Enterprise Linux 7libasanWill not fix
Out of support scope
Red Hat Enterprise Linux 7libasan-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libatomicWill not fix
Out of support scope
Red Hat Enterprise Linux 7libatomic-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libcilkrtsWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgccWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgfortranWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgfortran-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgfortran4Will not fix
Out of support scope
Red Hat Enterprise Linux 7libgfortran5Will not fix
Out of support scope
Red Hat Enterprise Linux 7libgnatWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgnat-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgnat-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgoWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgo-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgo-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libgompWill not fix
Out of support scope
Red Hat Enterprise Linux 7libitmWill not fix
Out of support scope
Red Hat Enterprise Linux 7libitm-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7libitm-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libmpxWill not fix
Out of support scope
Red Hat Enterprise Linux 7libmudflapWill not fix
Out of support scope
Red Hat Enterprise Linux 7libmudflap-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7libmudflap-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libobjcWill not fix
Out of support scope
Red Hat Enterprise Linux 7libquadmathWill not fix
Out of support scope
Red Hat Enterprise Linux 7libquadmath-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7libquadmath-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libstdc++Will not fix
Out of support scope
Red Hat Enterprise Linux 7libstdc++-develWill not fix
Out of support scope
Red Hat Enterprise Linux 7libstdc++-docsWill not fix
Out of support scope
Red Hat Enterprise Linux 7libstdc++-staticWill not fix
Out of support scope
Red Hat Enterprise Linux 7libtsanWill not fix
Out of support scope
Red Hat Enterprise Linux 7libtsan-staticWill not fix
Out of support scope
Rocky Linux 8delveFixed0:1.5.0-2.module+el8.4.0+396+d2d16ae3RLSA-2021:3076
Rocky Linux 8go-toolsetFixed0:1.15.14-1.module+el8.4.0+632+4dba2916RLSA-2021:3076
Rocky Linux 8golangFixed0:1.15.14-1.module+el8.4.0+632+4dba2916RLSA-2021:3076
Alpine Linux 3.24goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.23goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.22goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.21goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.20goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.19goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.18goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.17goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.16goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.15goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.14goFixed1.16.2-r0ALPINE-CVE-2021-27918
Alpine Linux 3.13goFixed1.15.10-r0ALPINE-CVE-2021-27918
Go librarystdlibFixed1.16.1GO-2021-0234

What the vendor says

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

Vendor advisories:

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.