# CVE-2019-20478: Deserialization in n/a

> Remote code execution is possible in ruamel.yaml if the unsafe load method is used with untrusted input, requiring developers to use safe_load instead.

- **Severity:** Critical 9.8 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 19 Feb 2020
- **Updated:** 5 Aug 2024
- **Also known as:** DEBIAN-CVE-2019-20478, GHSA-xg77-mvwp-crp2, UBUNTU-CVE-2019-20478, openSUSE-SU-2024:11271-1, openSUSE-SU-2024:14164-1, openSUSE-SU-2026:11904-1

## What is CVE-2019-20478?

CVE-2019-20478 is a critical unsafe deserialization vulnerability in n/a, published on 19 Feb 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

In ruamel.yaml through 0.16.7, the load method allows remote code execution if the application calls this method with an untrusted argument. In other words, this issue affects developers who are unaware of the need to use methods such as safe_load in these use cases.

## Which versions are affected by CVE-2019-20478?

It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `python-ruaeml.yaml` | openSUSE:Tumbleweed | All versions | 0.18.6-1.2 |
| `python-ruamel.yaml` | openSUSE:Tumbleweed | All versions | 0.19.1-2.1 |

Products: Ruamel.yaml Project Ruamel.yaml.

## How do I fix CVE-2019-20478?

Apply the vendor's patch.

## Is CVE-2019-20478 being exploited?

There is no known exploitation of CVE-2019-20478 in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2019-20478 and fix it if it is affected.

What it is: CVE-2019-20478 is a critical unsafe deserialization vulnerability in n/a, published on 19 Feb 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2019-20478 in the wild and no public exploit code.

Affected product: n/a. No package-level version data is available, so check the vendor advisory linked from the reference page.

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2019-20478/ (Markdown: https://insights.sbomify.com/CVE-2019-20478/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2019-20478
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2019-20478
- OSV: https://osv.dev/vulnerability/CVE-2019-20478

---
From sbomify Insights: https://insights.sbomify.com/CVE-2019-20478/
Summaries are generated and may contain mistakes; the official description above is the record.
