Description
In PyYAML before 5.1, the yaml.load() API could execute arbitrary code if used with untrusted data. The load() function has been deprecated in version 5.1 and the 'UnsafeLoader' has been introduced for backward compatibility with the function.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | pyyaml | 5.1.2-1 | — |
| Debian 13 | pyyaml | 5.1.2-1 | — |
| Debian 12 | pyyaml | 5.1.2-1 | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 18.04 LTS | pyyaml | No fix yet | — |
| Ubuntu 16.04 LTS | pyyaml | No fix yet | — |
| Ubuntu 14.04 LTS | pyyaml | No fix yet | — |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | oci-cli | 3.0.2-1.2 | openSUSE-SU-2024:11108-1 |
| openSUSE Tumbleweed | python-PyYAML | 5.4.1-1.6 | openSUSE-SU-2026:11996-1, openSUSE-SU-2024:14089-1, openSUSE-SU-2024:11210-1 |
| openSUSE Tumbleweed | python-openapi-spec-validator | 0.7.1-1.3 | openSUSE-SU-2026:11192-1, openSUSE-SU-2024:14152-1 |
Oracle Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Oracle Linux 8 | python3-olamkit +2 | 1.0.2-1.el8 | ELSA-2022-9341 |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| PyPI | pyyaml | < 5.1 | 5.1 | GHSA-rprw-h62v-c2w7 |
Advisories 9
- openSUSE-SU-2026:11996-1 python313-PyYAML-6.0.3-1.6 on GA media SUSE / openSUSE Security Updates · Oct 5, 2026
- WID-SEC-2024-0054 IBM Security Verify Access: Mehrere Schwachstellen BSI CERT-Bund (WID) · Jul 16, 2026
- openSUSE-SU-2026:11192-1 python313-openapi-spec-validator-0.9.0-1.1 on GA media SUSE / openSUSE Security Updates · Jul 7, 2026
- openSUSE-SU-2024:11210-1 python36-PyYAML-5.4.1-1.6 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- openSUSE-SU-2024:11108-1 oci-cli-3.0.2-1.2 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- openSUSE-SU-2024:14152-1 python310-openapi-spec-validator-0.7.1-1.3 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- openSUSE-SU-2024:14089-1 python310-PyYAML-6.0.1-4.1 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- WID-SEC-2024-1298 F5 BIG-IP: Schwachstelle ermöglicht Codeausführung BSI CERT-Bund (WID) · Jun 5, 2024
- ELSA-2022-9341 Important: ol-automation-manager security update (Oracle Linux 8) Oracle Linux Security Advisories (ELSA) · Apr 27, 2022
References
- https://github.com/yaml/pyyaml/pull/74
- https://github.com/yaml/pyyaml/blob/master/CHANGES
- FEDORA-2019-bed9afe622 vendor-advisory
- FEDORA-2019-779a9db46a vendor-advisory
- FEDORA-2019-44643e8bcb vendor-advisory
- https://github.com/marshmallow-code/apispec/issues/278
- https://github.com/yaml/pyyaml/issues/193
- https://github.com/yaml/pyyaml/wiki/PyYAML-yaml.load%28input%29-Deprecation
- GLSA-202003-45 vendor-advisory