Improper input validation in PyYAML
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- —
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Partial Red Hat: 4 fixed, 1 without a fix
Attack profile from CVSS 3.1 · NVD. Fix status from CNA, GitHub and Red Hat.
Summary
A vulnerability was discovered in the PyYAML library in versions before 5.4, where it is susceptible to arbitrary code execution when it processes untrusted YAML files through the full_load method or with the FullLoader loader. Applications that use the library to process untrusted input may be vulnerable to this flaw. This flaw allows an attacker to execute arbitrary code on the system by abusing the python/object/new constructor. This flaw is due to an incomplete fix for CVE-2020-1747.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | PyYAML | PyYAML 5.4 | — | No fix listed | CNA |
| — | PyYAML (PyPI) | before 5.4 | 5.4 | Patch available | GHSA-8q59-q68h-6hv4 |
- PyYAML Vendor— Affected PyYAML 5.4 Fixed in — No fix listed CNA
- PyYAML (PyPI) Vendor— Affected before 5.4 Fixed in 5.4 Patch available GHSA-8q59-q68h-6hv4
CPE configurations NVD · 3
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:pyyaml:pyyaml:*:*:*:*:*:*:*:* | 5.1 to before 5.4 | Vulnerable | Pyyaml |
| cpe:2.3:a:oracle:communications_cloud_native_core_network_function_cloud_native_environment:1.10.0:*:*:*:*:*:*:* | 1.10.0 | Vulnerable | Oracle |
| cpe:2.3:a:oracle:communications_cloud_native_core_network_function_cloud_native_environment:22.1.0:*:*:*:*:*:*:* | 22.1.0 | Vulnerable | Oracle |
- cpe:2.3:a:pyyaml:pyyaml:*:*:*:*:*:*:*:* Versions 5.1 to before 5.4 Vulnerable ·Pyyaml
- cpe:2.3:a:oracle:communications_cloud_native_core_network_function_cloud_native_environment:1.10.0:*:*:*:*:*:*:* Versions 1.10.0 Vulnerable ·Oracle
- cpe:2.3:a:oracle:communications_cloud_native_core_network_function_cloud_native_environment:22.1.0:*:*:*:*:*:*:* Versions 22.1.0 Vulnerable ·Oracle
Remediation
- Fix · GHSA-8q59-q68h-6hv4 PyYAML (PyPI) Fixed in 5.4 Advisory →
Red Hat 2 advisories
- RHSA-2021:4702 Released 2021-11-16 · Red Hat rating ModerateSatellite 6.10 Release
- Red Hat Satellite 6.10 candlepin-4.0.9-1.el7sat, foreman-2.5.2.17-2.el7sat, python-aiohttp-3.7.4-1.el7pc +14
- Red Hat Satellite Capsule 6.10 foreman-2.5.2.17-2.el7sat, python-aiohttp-3.7.4-1.el7pc, python-ecdsa-0.13.3-2.el7pc +9
- RHSA-2021:2583 Released 2021-06-29 · Red Hat rating Moderatepython38:3.8 and python38-devel:3.8 security update
- Red Hat CodeReady Linux Builder (v. 8) pytest-4.6.6-3.module+el8.4.0+8888+89bc7e79.src::python38-devel:3.8, python-atomicwrites-1.3.0-8.module+el8.4.0+8888+89bc7e79.src::python38-devel:3.8, python-attrs-19.3.0-3.module+el8.4.0+8888+89bc7e79.src::python38-devel:3.8 +15
- Red Hat Enterprise Linux AppStream (v. 8) Cython-0.29.14-4.module+el8.4.0+8888+89bc7e79.src::python38:3.8, PyYAML-5.4.1-1.module+el8.4.0+10706+5c295a3e.src::python38:3.8, babel-2.7.0-10.module+el8.4.0+8888+89bc7e79.src::python38:3.8 +47
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Software Collections | Affected | No fix planned: Will not fix |
| Red Hat CodeReady Linux Builder (v. 8) | Fixed | RHSA-2021:2583 |
| Red Hat Enterprise Linux AppStream (v. 8) | Fixed | RHSA-2021:2583 |
| Red Hat Satellite 6.10 | Fixed | RHSA-2021:4702 |
| Red Hat Satellite Capsule 6.10 | Fixed | RHSA-2021:4702 |
Not affected: 11 products
- Red Hat Ansible Tower 3
- Red Hat Enterprise Linux 6
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 8
- Red Hat Enterprise Linux 9
- Red Hat OpenStack Platform 10 (Newton)
- Red Hat OpenStack Platform 13 (Queens)
- Red Hat Quay 3
- Red Hat Satellite 6.10
- Red Hat Satellite Capsule 6.10
- Red Hat Software Collections
Timeline
- 2026-10-02 Threatist record created from CVE-2020-14343
- 2026-10-03 Alias added: GHSA-8q59-q68h-6hv4
References
Patch 2
Advisory 3
Other 7
- https://github.com/yaml/pyyaml/issues/420
- https://github.com/SeldonIO/seldon-core/issues/2252
- https://github.com/yaml/pyyaml/issues/420#issuecomment-663673966
- https://github.com/yaml/pyyaml/commit/a001f2782501ad2d24986959f0239a354675f9dc
- https://github.com/pypa/advisory-database/tree/main/vulns/pyyaml/PYSEC-2021-142.yaml
- https://github.com/yaml/pyyaml
- https://pypi.org/project/PyYAML
Sources
- CVE-2020-14343 · CVE Program
- CVE-2020-14343 · NVD
- FIRST EPSS
- GHSA-8q59-q68h-6hv4 · GitHub Advisory Database · CC BY 4.0
- CVE-2020-14343 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences