CVE-2026-138117
JSON

8.5high

HyperSpy before 2.6.0 Code Execution via sympy.sympify() in HSPY/ZSPY Files

Severity
8.5high CVSS:4.0 by VulnCheck
Exploit likelihood
0.25% (higher than 17% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
VulnCheck

Description

HyperSpy from 1.2.0 before 2.6.0 contains a code execution vulnerability that allows attackers to run Python code by embedding malicious expression strings evaluated with sympy.sympify(). Attackers can craft .hspy or .zspy files with malicious axis, Expression component, or twin function expressions that execute when victims call hs.load() or restore models.

Affected

Product or packageVersionsReported by
HyperSpy HyperSpyfrom 1.2.0 before 2.6.0CVE List

All scores

VulnCheck8.5high CVSS:4.0CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
VulnCheck7.8high CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Classification

References

https://github.com/hyperspy/hyperspy/security/advisories/GHSA-632c-gw75-99r3vendor-advisory
https://github.com/hyperspy/hyperspy/commit/fe484c936b9a1d425813e145298f9eeb1d83abf6patch
https://github.com/hyperspy/hyperspy/commit/973c9f9ce5937a022afe718f4f63c410eb96539epatch
https://github.com/hyperspy/hyperspy/releases/tag/v2.6.0release-notes
https://github.com/hyperspy/hyperspy/issues/3699issue-tracking
https://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/axes.py#L1031-L1071technical-description
https://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/_components/expression.py#L58-L66technical-description
https://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/component.py#L205-L217technical-description
https://www.vulncheck.com/advisories/hyperspy-before-2.6.0-code-execution-via-sympy-sympify-in-hspy-zspy-filesthird-party-advisory

Sources

SourceRecordLicence
CVE ListCVE-2026-138117 changed 2026-11-28CVE Terms of Use
NVDCVE-2026-138117 changed 2026-11-28Public domain