# CVE-2021-24040: Deserialization of Untrusted Data in parlai

- Severity: Critical 9.8 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/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): 17.4%, higher than 97% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2021-09-10T22:10:10.000Z
- Modified: 2026-07-09T16:45:06.451Z
- Also known as: GHSA-m87f-9fvv-2mgg, GHSA-mwgj-7x7j-6966, PYSEC-2021-330, PYSEC-2021-334
- Related: CVE-2021-39207
- Weaknesses: CWE-502
- Assigned by: facebook

## Description

Due to use of unsafe YAML deserialization logic, an attacker with the ability to modify local YAML configuration files could provide malicious input, resulting in remote code execution or similar risks. This issue affects ParlAI prior to v1.1.0.

(As written by CVE List.)

## Affected

- Facebook ParlAI: from unspecified before 1.1.0; before 1.1.0 (not affected: from 1.1.0 before unspecified)
- parlai (PyPI): before 1.1.0; before 507d066ef432ea27d3e201da08009872a2f37725; before 4374fa2aba383db6526ab36e939eb1cf8ef99879

## Every score

- GitHub: CVSS:3.1 8.4 Medium `CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:L`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:N/VI:N/VA:N/SC:H/SI:H/SA:L`
- GitHub: rating Medium
- NVD: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 7.5 High `AV:N/AC:L/Au:N/C:P/I:P/A:P`

## References

- <http://packetstormsecurity.com/files/164136/Facebook-ParlAI-1.0.0-Code-Execution-Deserialization.html> (exploit, third-party-advisory, vdb-entry, web)
- <https://github.com/facebookresearch/ParlAI/releases/tag/v1.1.0> (release-notes, third-party-advisory, web)
- <https://github.com/facebookresearch/ParlAI/security/advisories/GHSA-m87f-9fvv-2mgg> (advisory, patch, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-39207> (advisory)
- <https://github.com/facebookresearch/ParlAI/commit/4374fa2aba383db6526ab36e939eb1cf8ef99879> (fix, web)
- <https://github.com/facebookresearch/ParlAI/commit/507d066ef432ea27d3e201da08009872a2f37725> (fix, web)
- <https://github.com/advisories/GHSA-mwgj-7x7j-6966> (advisory)
- <https://github.com/facebookresearch/ParlAI> (package)
- <https://github.com/pypa/advisory-database/tree/main/vulns/parlai/PYSEC-2021-330.yaml> (web)
- <https://github.com/pypa/advisory-database/tree/main/vulns/parlai/PYSEC-2021-334.yaml> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-24040> (advisory)
- <https://github.com/facebookresearch/ParlAI/pull/3402> (web)
- <https://github.com/facebookresearch/ParlAI/pull/3429> (web)

## Sources

- CVE List: [CVE-2021-24040](https://www.cve.org/CVERecord?id=CVE-2021-24040), CVE Terms of Use, modified 2024-08-03
- GitHub Advisory Database: [GHSA-m87f-9fvv-2mgg](https://github.com/advisories/GHSA-m87f-9fvv-2mgg), CC-BY-4.0, modified 2026-07-08
- GitHub Advisory Database: [GHSA-mwgj-7x7j-6966](https://github.com/advisories/GHSA-mwgj-7x7j-6966), CC-BY-4.0, modified 2024-12-04
- NVD: [CVE-2021-24040](https://nvd.nist.gov/vuln/detail/CVE-2021-24040), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2021-330](https://osv.dev/vulnerability/PYSEC-2021-330), CC-BY-4.0, modified 2026-07-09
- PyPA Advisory Database: [PYSEC-2021-334](https://osv.dev/vulnerability/PYSEC-2021-334), CC-BY-4.0, modified 2023-11-08

---

Page: https://cve.day/CVE-2021-24040 · Whole record: https://cve.day/CVE-2021-24040.json · Rebuilt by cve.day 2026-11-25T22:58:03.891Z
