HyperSpy 1.4.0 before 2.6.0 Insecure Deserialization RCE via Stored Model Restoration
- State
- Published
- Severity
- 8.5 High
- Published
- Nov 28, 2026
- Updated
- Nov 30, 2026
- Reserved
- Nov 27, 2026
Description
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.
| Product | Versions |
|---|---|
| HyperSpy HyperSpy | 1.4.0 to before 2.6.0 Affected |
| CVSS | Score | How It's Reached | Source |
|---|---|---|---|
| 4.0 | 8.5 High | VulnCheck | |
| 3.1 | 7.8 High | VulnCheck |
Weaknesses
- CWE-502 Deserialization of Untrusted Data
References
- GitHub Security Advisory (GHSA-j975-x368-3hrr)Vendor Advisory
- Merge of PR #3704 (require trust for pickled model content)Patch
- Require explicit trust to restore pickled model componentsPatch
- HyperSpy v2.6.0 Release NotesRelease Notes
- GitHub issue #3699Issue Tracker
- reconstruct_component in model.py (v2.5.0)Technical Details
- Model._load_dictionary in model.py (v2.5.0)Technical Details
- reconstruct_object in export_dictionary.py (v2.5.0)Technical Details
- VulnCheck Advisory: HyperSpy 1.4.0 before 2.6.0 Insecure Deserialization RCE via Stored Model RestorationThird-Party Advisory
Every record here comes from the CVE Program's CVE List. © 1999-2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.