YAML versions before 1.30 for Perl allow a loaded document to trigger the DESTROY method of arbitrary classes

Summary

CVECVE-2017-20285
StatePUBLISHED
AssignerCPANSec
Source PriorityCVE Program / NVD first with legacy fallback
Published2026-10-05 07:16:29 UTC
Updated2026-10-06 17:17:08 UTC
DescriptionYAML versions before 1.30 for Perl allow a loaded document to trigger the DESTROY method of arbitrary classes. A perl/hash:Class tag blesses a hash into the class it names. The document supplies the object's fields, and Perl calls DESTROY when it goes out of scope. What DESTROY does depends on the classes the process has loaded. With File::Temp::Dir from core Perl, it can delete a directory tree the document names.

Risk And Classification

Primary CVSS: v3.1 9.1 CRITICAL from ADP

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N

EPSS: 0.001840000 probability, percentile 0.072500000 (date 2026-10-06)

Problem Types: CWE-470 | CWE-502 | CWE-502 CWE-502 Deserialization of Untrusted Data | CWE-470 CWE-470 Use of Externally-Controlled Input to Select Classes or Code ('Unsafe Reflection')


VersionSourceTypeScoreSeverityVector
3.1ADPDECLARED9.1CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
3.1134c704f-9b21-4f2e-91b3-4a467353bcc0Secondary9.1CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N

CVSS v3.1 Breakdown

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N

References

ReferenceSourceLinkTags
github.com/ingydotnet/yaml-pm/issues/176 9b29abf9-4ab0-4765-b253-1875cd9b441e github.com
metacpan.org/release/TINITA/YAML-1.30/changes 9b29abf9-4ab0-4765-b253-1875cd9b441e metacpan.org
github.com/ingydotnet/yaml-pm/commit/7736f38bd02e4f9f77d5468721e3be3d7b3... 9b29abf9-4ab0-4765-b253-1875cd9b441e github.com
github.com/ingydotnet/yaml-pm/commit/471314bbdcbd62077eea32755929122aa8b... 9b29abf9-4ab0-4765-b253-1875cd9b441e github.com
www.openwall.com/lists/oss-security/2026/10/05/8 af854a3a-2127-422b-91ae-364da2661108 www.openwall.com
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

Additional Advisory Data

SourceTimeEvent
CNA2017-05-10T00:00:00.000ZIssue reported.
CNA2018-05-11T00:00:00.000ZVersion 1.25 released with the $YAML::LoadBlessed option.
CNA2020-01-27T00:00:00.000ZVersion 1.30 released with the option defaulting to off.
CNA2022-06-27T00:00:00.000ZIssue added as CPANSA-YAML-2017-01 in the CPAN::Audit database.
CNA2026-09-21T00:00:00.000ZCVE number reserved.

Solutions

CNA: Upgrade to YAML 1.30 or later.

Workarounds

CNA: For deployments that cannot upgrade to YAML 1.30, set $YAML::LoadBlessed = 0 before loading untrusted input. The option exists from YAML 1.25.

© CVE.report 2026

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report