CVE-2021-20206
JSON

7.2high

containernetworking/cni improper limitation of path name

Severity
7.2high CVSS:3.1 by NVD
Exploit likelihood
1.52% (higher than 75% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
redhat
Also known as
GHSA-xjqr-g762-pxwpGO-2022-0230SNYK-GOLANG-GITHUBCOMCONTAINERNETWORKINGCNIPKGINVOKE-1070549

Description

An improper limitation of path name flaw was found in containernetworking/cni in versions before 0.8.1. When specifying the plugin to load in the 'type' field in the network configuration, it is possible to use special elements such as "../" separators to reference binaries elsewhere on the system. This flaw allows an attacker to execute other existing binaries other than the cni plugins/types, such as 'reboot'. The highest threat from this vulnerability is to confidentiality, integrity, as well as system availability.

Affected

Product or packageVersionsReported by
containernetworking-cnicontainernetworking/cni 0.8.1CVE List
github.com/containernetworking/cni (Go)before 0.8.1GitHub Advisory Database, Go Vulnerability Database
linuxfoundation container_network_interfacebefore 0.8.1NVD

All scores

GitHub7.2high CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
NVD7.2high CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
NVD6.5medium CVSS:2.0AV:N/AC:L/Au:S/C:P/I:P/A:P

Classification

What each source says

CVE List

An improper limitation of path name flaw was found in containernetworking/cni in versions before 0.8.1. When specifying the plugin to load in the 'type' field in the network configuration, it is possible to use special elements such as "../" separators to reference binaries elsewhere on the system. This flaw allows an attacker to execute other existing binaries other than the cni plugins/types, such as 'reboot'. The highest threat from this vulnerability is to confidentiality, integrity, as well as system availability.

GitHub Advisory Database

An improper limitation of path name flaw was found in containernetworking/cni in versions before 0.8.1. When specifying the plugin to load in the 'type' field in the network configuration, it is possible to use special elements such as "../" separators to reference binaries elsewhere on the system. This flaw allows an attacker to execute other existing binaries other than the cni plugins/types, such as 'reboot'. The highest threat from this vulnerability is to confidentiality, integrity, as well as system availability.

Specific Go Packages Affected

github.com/containernetworking/cni/pkg/invoke

Go Vulnerability Database

The FindInPath function is vulnerable to directory traversal attacks, potentially permitting attackers to execute arbitrary binaries.

This function does not sanitize its plugin parameter, so parameter names containing "../" or other such elements may reference arbitrary locations on the filesystem.

NVD (es)

Se detectó una limitación inapropiada del fallo en el nombre de la ruta en containernetworking/cni en versiones anteriores a 0.8.1. Cuando se especifica el plugin a cargar en el campo "type" en la configuración de red, es posible usar elementos especiales como separadores "../" para hacer referencia a binarios en otras partes del sistema. Este fallo permite a un atacante ejecutar otros binarios existentes que no sean los plugins y tipos de cni, como "reboot". La mayor amenaza de esta vulnerabilidad es la confidencialidad, la integridad y la disponibilidad del sistema.

References

Sources

SourceRecordLicence
CVE ListCVE-2021-20206 changed 2024-08-03CVE Terms of Use
GitHub Advisory DatabaseGHSA-xjqr-g762-pxwp changed 2026-09-10CC-BY-4.0
Go Vulnerability DatabaseGO-2022-0230 changed 2026-03-13CC-BY-4.0
NVDCVE-2021-20206 changed 2026-06-17Public domain