GitHub Advisoryadvisory · PyPI
GHSA-rprw-h62v-c2w7 PyYAML insecurely deserializes YAML strings leading to arbitrary code execution
CRITICAL
Official page ↗
- Aliases
- CVE-2017-18342
- Ecosystem
- PyPI
- Packages
- PyYAML
- Severity
- Critical
- CVSS vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Weaknesses
- CWE-502
- Reviewed
- 2020-06-16
Affected packages
• PyPI PyYAML: < 5.1 → fixed in 5.1
Description
In PyYAML before 5.1, the `yaml.load()` API could execute arbitrary code. In other words, `yaml.safe_load` is not used.
This was intended to be fixed in 4.1, but due to breaking changes, 4.1 was yanked and 5.1 contains the patch for CVE-2017-18342.
Related
Alias · CVE (1)
- CVE-2017-18342 In PyYAML before 5.1, the yaml.load() API could execute arbitrary code if used with untrusted data. vulnerability
Weakness · CWE (1)
- CWE-502 Deserialization of Untrusted Data weakness
References
- https://nvd.nist.gov/vuln/detail/CVE-2017-18342 advisory
- https://github.com/marshmallow-code/apispec/issues/278 web
- https://github.com/yaml/pyyaml/issues/193 web
- https://github.com/yaml/pyyaml/issues/207#issuecomment-472520007 web
- https://github.com/yaml/pyyaml/pull/74 web
- https://github.com/yaml/pyyaml/commit/7b68405c81db889f83c32846462b238ccae5be80 web
- https://github.com/pypa/advisory-database/tree/main/vulns/pyyaml/PYSEC-2018-49.yaml web
- https://github.com/yaml/pyyaml package
- https://github.com/yaml/pyyaml/blob/master/CHANGES web
- https://github.com/yaml/pyyaml/wiki/PyYAML-yaml.load(input)-Deprecation web
- https://lists.fedoraproject.org/archives/list/[email protected]/message/JEX7IPV5P2QJITAMA5Z63GQCZA5I6NVZ web
- https://lists.fedoraproject.org/archives/list/[email protected]/message/KSQQMRUQSXBSUXLCRD3TSZYQ7SEZRKCE web
- https://lists.fedoraproject.org/archives/list/[email protected]/message/M6JCFGEIEOFMWWIXGHSELMKQDD4CV2BA web
- https://security.gentoo.org/glsa/202003-45 web