CVE-2025-54413
skops' MethodNode can access unexpected object fields through dot notation, leading to arbitrary code execution at load time
skops is a Python library which helps users share and ship their scikit-learn based models. Versions 0.11.0 and below contain an inconsistency in MethodNode, which can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time. While this issue may seem similar to GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types. This is fixed in version 12.0.0.
Attack profile
How easy it is to exploit
- Attack vector
- Local
- Complexity
- Low
- Privileges needed
- None
- User interaction
- Active
What an attacker can affect
- Confidentiality
- High
- Integrity
- High
- Availability
- High
Exploit likelihood
What each source reports
CVE List Score used
8.7
skops' MethodNode can access unexpected object fields through dot notation, leading to arbitrary code execution at load time
skops is a Python library which helps users share and ship their scikit-learn based models. Versions 0.11.0 and below contain an inconsistency in MethodNode, which can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time. While this issue may seem similar to GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types. This is fixed in version 12.0.0.
- Record
CVE-2025-54413- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - Weakness
- CWE-351
- Updated
- 2026-11-02
EUVDEUVD-2025-22762
8.7
skops is a Python library which helps users share and ship their scikit-learn based models. Versions 0.11.0 and below contain an inconsistency in MethodNode, which can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time. While this issue may seem similar to GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types. This is fixed in version 12.0.0.
- Record
EUVD-2025-22762- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - Updated
- 2026-11-02
GitHub AdvisoriesGHSA-4v6w-xpmh-gfgp
8.7
Skops may allow MethodNode to access unexpected object fields through dot notation, leading to arbitrary code execution at load time
Summary
An inconsistency in MethodNode can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time.
While this issue may seem similar to https://github.com/skops-dev/skops/security/advisories/GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types.
Details
The MethodNode allows access to attributes of existing objects via dot notation. However, there are several critical shortcomings:
-
Although the
__class__and__module__fields are checked viaget_untrusted_typesand during theloadphase (as a concatenated string), they are not actually used byMethodNode. Instead, thefuncandobjentries in theschema.jsonare used to determine behavior. This means that even an apparently harmless__module__.__class__pair can lead to access of arbitrary attributes or methods of loaded objects, without any additional checks. -
Nothing prevents an attacker from chaining multiple
MethodNodeinstances to traverse the object hierarchy and access harmful attributes.
An object can be loaded using the ObjectNode, which normally enforces strict checks and allows only trusted or explicitly permitted objects. However, once the object is loaded, dot notation can be used to access any of its attributes or methods. Furthermore, by chaining multiple MethodNodes, one can traverse the Python object hierarchy and reach dangerous components such as the builtins dictionary—which contains functions like exec and eval.
This vulnerability allows the attacker to bypass both get_untrusted_types and load checks, enabling access to dangerous attributes and methods without triggering any alerts. As demonstrated in the PoC, arbitrary code execution is possible using just an anonymous object returned by get_untrusted_types (in the example, builtins.int, though any type would suffice since it doesn't influence the exploit).
For example, consider a malicious schema.json snippet like:
...
"__class__": "int",
"__module__": "builtins",
"__loader__": "MethodNode",
"content": {
"obj": {
"__class__": "int",
"__module__": "builtins",
"__loader__": "MethodNode",
"content": {
"obj": {
"__class__": "QuadraticDiscriminantAnalysis",
"__module__": "sklearn.discriminant_analysis",
"__loader__": "ObjectNode",
"__id__": 1
},
"func": "decision_function"
}
},
"func": "__builtins__"
}
...
Here, the attacker loads a trusted QuadraticDiscriminantAnalysis object using ObjectNode, accesses its decision_function method via MethodNode, and then uses another MethodNode to access the __builtins__ dictionary—all without triggering the untrusted type detection mechanisms.
Proof of Concept (PoC)
The provided PoC demonstrates arbitrary code execution using only builtins.int as the type returned by get_untrusted_types and verified by load. Note that the actual type is fully controlled by the attacker and can be anything (e.g., provola.whatever), as it's not used by skops or the exploit.
Components Used in the Exploit
To craft the exploit, the following skops nodes are used:
MethodNode– to silently access arbitrary Python attributes via dot notation. This is the vulnerable core.ObjectNode– to load a trusted object and use it as a base to access its attributes and methods. Also used to set object state via__setstate__.PartialNode– to easily control arguments passed to functions accessed.DefaultDictNode– to store a crafted call toexecusing thedefault_factoryattribute.DictNode– to trigger the call at load time.JsonNode,TypeNode,ListNode, etc. – for basic types, structures, and constants.
Additionally, the interesting implementation of GridSearchCV.score was leveraged, specifically:…
- Record
GHSA-4v6w-xpmh-gfgp- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - Weakness
- CWE-351
- Updated
- 2026-11-02
NVD
8.7
skops is a Python library which helps users share and ship their scikit-learn based models. Versions 0.11.0 and below contain an inconsistency in MethodNode, which can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time. While this issue may seem similar to GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types. This is fixed in version 12.0.0.
- Record
CVE-2025-54413- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - Weakness
- CWE-351
- Updated
- 2026-11-02
OSV
8.7
skops' MethodNode can access unexpected object fields through dot notation, leading to arbitrary code execution at load time
skops is a Python library which helps users share and ship their scikit-learn based models. Versions 0.11.0 and below contain an inconsistency in MethodNode, which can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time. While this issue may seem similar to GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types. This is fixed in version 12.0.0.
- Record
CVE-2025-54413- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - Weakness
- CWE-351
- Updated
- 2026-11-02
OSVGHSA-4v6w-xpmh-gfgp
8.7
Skops may allow MethodNode to access unexpected object fields through dot notation, leading to arbitrary code execution at load time
Summary
An inconsistency in MethodNode can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time.
While this issue may seem similar to https://github.com/skops-dev/skops/security/advisories/GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types.
Details
The MethodNode allows access to attributes of existing objects via dot notation. However, there are several critical shortcomings:
-
Although the
__class__and__module__fields are checked viaget_untrusted_typesand during theloadphase (as a concatenated string), they are not actually used byMethodNode. Instead, thefuncandobjentries in theschema.jsonare used to determine behavior. This means that even an apparently harmless__module__.__class__pair can lead to access of arbitrary attributes or methods of loaded objects, without any additional checks. -
Nothing prevents an attacker from chaining multiple
MethodNodeinstances to traverse the object hierarchy and access harmful attributes.
An object can be loaded using the ObjectNode, which normally enforces strict checks and allows only trusted or explicitly permitted objects. However, once the object is loaded, dot notation can be used to access any of its attributes or methods. Furthermore, by chaining multiple MethodNodes, one can traverse the Python object hierarchy and reach dangerous components such as the builtins dictionary—which contains functions like exec and eval.
This vulnerability allows the attacker to bypass both get_untrusted_types and load checks, enabling access to dangerous attributes and methods without triggering any alerts. As demonstrated in the PoC, arbitrary code execution is possible using just an anonymous object returned by get_untrusted_types (in the example, builtins.int, though any type would suffice since it doesn't influence the exploit).
For example, consider a malicious schema.json snippet like:
...
"__class__": "int",
"__module__": "builtins",
"__loader__": "MethodNode",
"content": {
"obj": {
"__class__": "int",
"__module__": "builtins",
"__loader__": "MethodNode",
"content": {
"obj": {
"__class__": "QuadraticDiscriminantAnalysis",
"__module__": "sklearn.discriminant_analysis",
"__loader__": "ObjectNode",
"__id__": 1
},
"func": "decision_function"
}
},
"func": "__builtins__"
}
...
Here, the attacker loads a trusted QuadraticDiscriminantAnalysis object using ObjectNode, accesses its decision_function method via MethodNode, and then uses another MethodNode to access the __builtins__ dictionary—all without triggering the untrusted type detection mechanisms.
Proof of Concept (PoC)
The provided PoC demonstrates arbitrary code execution using only builtins.int as the type returned by get_untrusted_types and verified by load. Note that the actual type is fully controlled by the attacker and can be anything (e.g., provola.whatever), as it's not used by skops or the exploit.
Components Used in the Exploit
To craft the exploit, the following skops nodes are used:
MethodNode– to silently access arbitrary Python attributes via dot notation. This is the vulnerable core.ObjectNode– to load a trusted object and use it as a base to access its attributes and methods. Also used to set object state via__setstate__.PartialNode– to easily control arguments passed to functions accessed.DefaultDictNode– to store a crafted call toexecusing thedefault_factoryattribute.DictNode– to trigger the call at load time.JsonNode,TypeNode,ListNode, etc. – for basic types, structures, and constants.
Additionally, the interesting implementation of GridSearchCV.score was leveraged, specifically:…
- Record
GHSA-4v6w-xpmh-gfgp- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - Weakness
- CWE-351
- Updated
- 2026-11-02
OSVPYSEC-2026-1926
8.7
Skops may allow MethodNode to access unexpected object fields through dot notation, leading to arbitrary code execution at load time
Summary
An inconsistency in MethodNode can be exploited to access unexpected object fields through dot notation. This can be used to achieve arbitrary code execution at load time.
While this issue may seem similar to https://github.com/skops-dev/skops/security/advisories/GHSA-m7f4-hrc6-fwg3, it is actually more severe, as it relies on fewer assumptions about trusted types.
Details
The MethodNode allows access to attributes of existing objects via dot notation. However, there are several critical shortcomings:
-
Although the
__class__and__module__fields are checked viaget_untrusted_typesand during theloadphase (as a concatenated string), they are not actually used byMethodNode. Instead, thefuncandobjentries in theschema.jsonare used to determine behavior. This means that even an apparently harmless__module__.__class__pair can lead to access of arbitrary attributes or methods of loaded objects, without any additional checks. -
Nothing prevents an attacker from chaining multiple
MethodNodeinstances to traverse the object hierarchy and access harmful attributes.
An object can be loaded using the ObjectNode, which normally enforces strict checks and allows only trusted or explicitly permitted objects. However, once the object is loaded, dot notation can be used to access any of its attributes or methods. Furthermore, by chaining multiple MethodNodes, one can traverse the Python object hierarchy and reach dangerous components such as the builtins dictionary—which contains functions like exec and eval.
This vulnerability allows the attacker to bypass both get_untrusted_types and load checks, enabling access to dangerous attributes and methods without triggering any alerts. As demonstrated in the PoC, arbitrary code execution is possible using just an anonymous object returned by get_untrusted_types (in the example, builtins.int, though any type would suffice since it doesn't influence the exploit).
For example, consider a malicious schema.json snippet like:
...
"__class__": "int",
"__module__": "builtins",
"__loader__": "MethodNode",
"content": {
"obj": {
"__class__": "int",
"__module__": "builtins",
"__loader__": "MethodNode",
"content": {
"obj": {
"__class__": "QuadraticDiscriminantAnalysis",
"__module__": "sklearn.discriminant_analysis",
"__loader__": "ObjectNode",
"__id__": 1
},
"func": "decision_function"
}
},
"func": "__builtins__"
}
...
Here, the attacker loads a trusted QuadraticDiscriminantAnalysis object using ObjectNode, accesses its decision_function method via MethodNode, and then uses another MethodNode to access the __builtins__ dictionary—all without triggering the untrusted type detection mechanisms.
Proof of Concept (PoC)
The provided PoC demonstrates arbitrary code execution using only builtins.int as the type returned by get_untrusted_types and verified by load. Note that the actual type is fully controlled by the attacker and can be anything (e.g., provola.whatever), as it's not used by skops or the exploit.
Components Used in the Exploit
To craft the exploit, the following skops nodes are used:
MethodNode– to silently access arbitrary Python attributes via dot notation. This is the vulnerable core.ObjectNode– to load a trusted object and use it as a base to access its attributes and methods. Also used to set object state via__setstate__.PartialNode– to easily control arguments passed to functions accessed.DefaultDictNode– to store a crafted call toexecusing thedefault_factoryattribute.DictNode– to trigger the call at load time.JsonNode,TypeNode,ListNode, etc. – for basic types, structures, and constants.
Additionally, the interesting implementation of GridSearchCV.score was leveraged, specifically:…
- Record
PYSEC-2026-1926- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - Updated
- 2026-11-02
Affected products
Affected packages
History
| Recorded | Changed | Sources |
|---|---|---|
| first indexed | CVE List, EUVD, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2025-54413 is a high vulnerability (CVSS 8.7) in Skops-dev Skops, published July 25, 2025. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.16%, the 5th percentile. Fixed in skops 0.12.0.
References
github.com/skops-dev/skops/security/advisories/GHSA-4v6w-xpmh-gfgp
github.com/skops-dev/skops/security/advisories/GHSA-m7f4-hrc6-fwg3
github.com/skops-dev/skops/commit/0aeca055509dfb48c1506870aabdd9e247adf603
drive.google.com/drive/folders/1bmVV18mnPbWy21hVYgf51yVJpf78vtB_?usp=sharing
github.com/skops-dev/skops/releases/tag/v0.12.0
nvd.nist.gov/vuln/detail/CVE-2025-54413
Left out here: the rest of 3 source descriptions. The JSON record has them.