CVE-2026-138118
NVD
Vulnerability Summary
HyperSpy from 1.4.0 before 2.6.0 contains an insecure deserialization vulnerability that allows attackers to execute arbitrary Python code by supplying crafted stored-model data in .hspy or .zspy files. Attackers can embed a malicious pickle payload in a component's _class_dump or a 'fn'-flagged _whitelist entry, which cloudpickle.loads() (dill in 1.x) runs when the victim restores the model.
CVSS v4.0 Base Metrics — Score 8.5 (HIGH)
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:NAttack VectorLocal
Attack ComplexityLow
Attack RequirementsNone
Privileges RequiredNone
User InteractionPassive
Confidentiality (Vulnerable System)High
Integrity (Vulnerable System)High
Availability (Vulnerable System)High
Confidentiality (Subsequent System)None
Integrity (Subsequent System)None
Availability (Subsequent System)None
Show CVSS v3.x metrics (score 7.8)
CVSS v3.1 Base Metrics — Score 7.8 (HIGH)
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:HAttack VectorLocal
Attack ComplexityLow
Privileges RequiredNone
User InteractionRequired
ScopeUnchanged
ConfidentialityHigh
IntegrityHigh
AvailabilityHigh
Affected & Patched Versions
- HyperSpy >= 1.4.0 and < 2.6.0
- HyperSpy 2.6.0
What to do
Plan remediation soon. No exploitation is confirmed yet, but the severity is high.
- Check whether you run HyperSpy and which version.
- Update to a patched version listed above, then confirm the new version.
Timeline
- Nov 28, 2026Published
- Nov 28, 2026Record last modified
Score, severity and exploitation changes are tracked from the day Watchtower started logging them.
Get notified about new HyperSpy CVEsYou are reading CVE-2026-138118. Get an email when KEV listings, exploits or new CVEs match your stack.
Set up CVE alertsExternal References
- Vendor Advisoryhttps://github.com/hyperspy/hyperspy/security/advisories/GHSA-j975-x368-3hrr
- Patchhttps://github.com/hyperspy/hyperspy/commit/6382ae0ff5b0000a7aad5dc2f4b997b1d8dccb09
- Patchhttps://github.com/hyperspy/hyperspy/commit/28fdf2d0320c76c5d57a57e323ac510b2005e13d
- Referencehttps://github.com/hyperspy/hyperspy/releases/tag/v2.6.0
- Issue Trackinghttps://github.com/hyperspy/hyperspy/issues/3699
- Referencehttps://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/model.py#L106-L146
- Referencehttps://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/model.py#L645-L661
- Referencehttps://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/misc/export_dictionary.py#L187-L207
- Referencehttps://www.vulncheck.com/advisories/hyperspy-1.4.0-before-2.6.0-insecure-deserialization-rce-via-stored-model-restoration
Data last checked: Nov 29, 2026 22:08 UTC