{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2026-138117",
        "assignerOrgId": "83251b91-4cc7-4094-a5c7-464a1b83ea10",
        "state": "PUBLISHED",
        "assignerShortName": "VulnCheck",
        "dateReserved": "2026-11-27T23:50:24.916Z",
        "datePublished": "2026-11-28T01:43:09.488Z",
        "dateUpdated": "2026-12-01T21:52:59.627Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "83251b91-4cc7-4094-a5c7-464a1b83ea10",
                "shortName": "VulnCheck",
                "dateUpdated": "2026-11-28T01:43:09.488Z"
            },
            "datePublic": "2026-11-27T00:00:00.000Z",
            "title": "HyperSpy before 2.6.0 Code Execution via sympy.sympify() in HSPY/ZSPY Files",
            "descriptions": [
                {
                    "lang": "en",
                    "value": "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."
                }
            ],
            "problemTypes": [
                {
                    "descriptions": [
                        {
                            "lang": "en",
                            "description": "Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')",
                            "cweId": "CWE-95",
                            "type": "CWE"
                        }
                    ]
                }
            ],
            "affected": [
                {
                    "vendor": "HyperSpy",
                    "product": "HyperSpy",
                    "defaultStatus": "unaffected",
                    "versions": [
                        {
                            "version": "1.2.0",
                            "lessThan": "2.6.0",
                            "status": "affected",
                            "versionType": "semver"
                        }
                    ],
                    "packageURL": "pkg:pypi/hyperspy",
                    "repo": "https://github.com/hyperspy/hyperspy"
                }
            ],
            "metrics": [
                {
                    "format": "CVSS",
                    "cvssV4_0": {
                        "version": "4.0",
                        "vectorString": "CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N",
                        "attackVector": "LOCAL",
                        "attackComplexity": "LOW",
                        "attackRequirements": "NONE",
                        "privilegesRequired": "NONE",
                        "userInteraction": "PASSIVE",
                        "vulnConfidentialityImpact": "HIGH",
                        "vulnIntegrityImpact": "HIGH",
                        "vulnAvailabilityImpact": "HIGH",
                        "subConfidentialityImpact": "NONE",
                        "subIntegrityImpact": "NONE",
                        "subAvailabilityImpact": "NONE",
                        "baseScore": 8.5,
                        "baseSeverity": "HIGH"
                    }
                },
                {
                    "format": "CVSS",
                    "cvssV3_1": {
                        "version": "3.1",
                        "vectorString": "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H",
                        "attackVector": "LOCAL",
                        "attackComplexity": "LOW",
                        "privilegesRequired": "NONE",
                        "userInteraction": "REQUIRED",
                        "scope": "UNCHANGED",
                        "confidentialityImpact": "HIGH",
                        "integrityImpact": "HIGH",
                        "availabilityImpact": "HIGH",
                        "baseScore": 7.8,
                        "baseSeverity": "HIGH"
                    }
                }
            ],
            "references": [
                {
                    "url": "https://github.com/hyperspy/hyperspy/security/advisories/GHSA-632c-gw75-99r3",
                    "tags": [
                        "vendor-advisory"
                    ],
                    "name": "GitHub Security Advisory (GHSA-632c-gw75-99r3)"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/commit/fe484c936b9a1d425813e145298f9eeb1d83abf6",
                    "tags": [
                        "patch"
                    ],
                    "name": "Merge of PR #3703 (bounded expression parser)"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/commit/973c9f9ce5937a022afe718f4f63c410eb96539e",
                    "tags": [
                        "patch"
                    ],
                    "name": "fix(security): parse file-derived expressions with the bounded parser"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/releases/tag/v2.6.0",
                    "tags": [
                        "release-notes"
                    ],
                    "name": "HyperSpy v2.6.0 Release Notes"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/issues/3699",
                    "tags": [
                        "issue-tracking"
                    ],
                    "name": "GitHub issue #3699"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/axes.py#L1031-L1071",
                    "tags": [
                        "technical-description"
                    ],
                    "name": "FunctionalDataAxis.__init__ in axes.py (v2.5.0)"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/_components/expression.py#L58-L66",
                    "tags": [
                        "technical-description"
                    ],
                    "name": "_parse_substitutions in expression.py (v2.5.0)"
                },
                {
                    "url": "https://github.com/hyperspy/hyperspy/blob/v2.5.0/hyperspy/component.py#L205-L217",
                    "tags": [
                        "technical-description"
                    ],
                    "name": "twin_function_expr setter in component.py (v2.5.0)"
                },
                {
                    "url": "https://www.vulncheck.com/advisories/hyperspy-before-2.6.0-code-execution-via-sympy-sympify-in-hspy-zspy-files",
                    "name": "VulnCheck Advisory: HyperSpy before 2.6.0 Code Execution via sympy.sympify() in HSPY/ZSPY Files",
                    "tags": [
                        "third-party-advisory"
                    ]
                }
            ],
            "credits": [
                {
                    "lang": "en",
                    "value": "Dilanka Kaushal Hewage",
                    "type": "finder"
                },
                {
                    "lang": "en",
                    "value": "Nils Jordan",
                    "type": "finder"
                }
            ],
            "x_generator": {
                "engine": "vulncheck-endgame"
            }
        },
        "adp": [
            {
                "references": [
                    {
                        "url": "https://github.com/hyperspy/hyperspy/security/advisories/GHSA-632c-gw75-99r3",
                        "tags": [
                            "exploit"
                        ]
                    }
                ],
                "metrics": [
                    {
                        "other": {
                            "type": "ssvc",
                            "content": {
                                "timestamp": "2026-12-01T21:52:33.617788Z",
                                "id": "CVE-2026-138117",
                                "options": [
                                    {
                                        "Exploitation": "poc"
                                    },
                                    {
                                        "Automatable": "no"
                                    },
                                    {
                                        "Technical Impact": "total"
                                    }
                                ],
                                "role": "CISA Coordinator",
                                "version": "2.0.3"
                            }
                        }
                    }
                ],
                "title": "CISA ADP Vulnrichment",
                "providerMetadata": {
                    "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
                    "shortName": "CISA-ADP",
                    "dateUpdated": "2026-12-01T21:52:59.627Z"
                }
            }
        ]
    }
}