# CVE-2021-43811: Code injection via unsafe YAML loading

- Severity: High 7.8 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 2.47%, higher than 84% of CVEs (2026-12-01)
- Published: 2021-12-08T23:05:11.000Z
- Modified: 2026-07-08T06:29:38.266Z
- Also known as: GHSA-ggmr-44cv-24pm, PYSEC-2021-848
- Weaknesses: CWE-94
- Assigned by: GitHub_M

## Description

Sockeye is an open-source sequence-to-sequence framework for Neural Machine Translation built on PyTorch. Sockeye uses YAML to store model and data configurations on disk. Versions below 2.3.24 use unsafe YAML loading, which can be made to execute arbitrary code embedded in config files. An attacker can add malicious code to the config file of a trained model and attempt to convince users to download and run it. If users run the model, the embedded code will run locally. The issue is fixed in version 2.3.24.

(As written by CVE List.)

## Affected

- awslabs sockeye: < 2.3.24
- sockeye (PyPI): before 2.3.24
- amazon sockeye: before 2.3.24

## Every score

- GitHub_M: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H`
- GitHub: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 6.8 Medium `AV:N/AC:M/Au:N/C:P/I:P/A:P`

## References

- <https://github.com/awslabs/sockeye/security/advisories/GHSA-ggmr-44cv-24pm> (advisory, third-party-advisory, web)
- <https://github.com/awslabs/sockeye/pull/964> (patch, third-party-advisory, web)
- <https://github.com/awslabs/sockeye/releases/tag/2.3.24> (release-notes, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-43811> (advisory)
- <https://github.com/awslabs/sockeye> (package)
- <https://github.com/pypa/advisory-database/tree/main/vulns/sockeye/PYSEC-2021-848.yaml> (web)

## Sources

- CVE List: [CVE-2021-43811](https://www.cve.org/CVERecord?id=CVE-2021-43811), CVE Terms of Use, modified 2024-08-04
- GitHub Advisory Database: [GHSA-ggmr-44cv-24pm](https://github.com/advisories/GHSA-ggmr-44cv-24pm), CC-BY-4.0, modified 2026-07-08
- NVD: [CVE-2021-43811](https://nvd.nist.gov/vuln/detail/CVE-2021-43811), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2021-848](https://osv.dev/vulnerability/PYSEC-2021-848), CC-BY-4.0, modified 2023-11-08

---

Page: https://cve.day/CVE-2021-43811 · Whole record: https://cve.day/CVE-2021-43811.json · Rebuilt by cve.day 2026-11-25T22:24:36.192Z
