Skip to main content

HCIPy EUVDEUVD-2026-137351

| CVE-2026-137997 HIGH
Deserialization of Untrusted Data (CWE-502)
2026-11-27 VulnCheck GHSA-q538-gr46-hr2p
8.5
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Craft malicious .pkl with __reduce__ gadget
  2. Delivery
    Deliver file to researcher via shared dataset
  3. Exploit
    Victim loads it via read_field/read_grid/read_mode_basis
  4. Execution
    pickle.load executes gadget
  5. Impact
    Code runs with user's privileges

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A08:2025 - Software or Data Integrity Failures
ASVS 5.0
V1 - Encoding and Sanitization Safe deserialization, type allowlists
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires a user to load an attacker-controlled file with a pickle extension (e.g. .pkl) through hcipy.read_field, read_grid, or read_mode_basis; because hcipy/util/io.py (v0.7.1, lines 262-264) auto-selects the pickle format from the file extension and calls pickle.load, a __reduce__ gadget in the file runs on load. Limiting factors: the vector is LOCAL (AV:L) - there is no network-exposed service, so the attacker must deliver the crafted file to the victim; and it needs passive user interaction (UI:P) - the victim must actually open/read the malicious file. It affects the default behavior of these read functions for pickle-extension files in versions through 0.7.1; the patch removes pickle auto-detection so pickle must be requested explicitly via fmt='pickle' and emits a deprecation warning.

Impact

This is a genuine arbitrary-code-execution flaw (CWE-502, unsafe pickle.load) but the real-world risk is bounded by its delivery requirements, not its impact. The input CVSS 4.0 vector (AV:L, AC:L, AT:N, PR:N, UI:P, VC/VI/VA:H) and the description agree: exploitation is LOCAL and requires the victim to open an attacker-supplied .pkl file through read_field, read_grid or read_mode_basis - it is not remotely triggerable against a service. The UI:P (passive user interaction) metric is the key limiter: an attacker must get a crafted pupil/apodizer/PSF/mode-basis file in front of a user who then loads it. No EPSS score and no KEV listing are present in the input, and there is no confirmed working-exploit reference - only the advisory, bug issue, and patch. The vendor decision label is 'this_week' (not act_now/emergency), consistent with a high-impact-but-non-wormable, interaction-gated issue affecting a niche scientific library. Net: real and worth patching this week, but this is a high-severity flaw with a narrow, social-engineering-style delivery path rather than a mass-exploitation priority.

Exploit ScenarioDerived

An attacker crafts a malicious .pkl file whose embedded object defines a __reduce__ gadget (e.g. disguised as a telescope pupil, apodizer, PSF, or mode-basis dataset) and shares it with a researcher - via a data repository, email, or collaboration channel. When the victim loads it with hcipy.read_field/read_grid/read_mode_basis, io.py selects pickle by file extension and calls pickle.load, executing the attacker's code with the user's privileges. No public working exploit is identified in the provided data, though the mechanism is straightforward and well understood for pickle gadgets.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 27, 2026

Insecure deserialization in HCIPy through 0.7.1 allows arbitrary code execution when a user loads a crafted .pkl file through read_field, read_grid or read_mode_basis. The library's io module auto-selects the pickle format from the file extension and calls pickle.load, so a __reduce__ gadget embedded in a saved pupil, apodizer, PSF or mode-basis object runs with the victim's privileges; the assessed vector is local (AV:L) with passive user interaction (UI:R/UI:P), meaning an attacker must first deliver the malicious file to the target. Impact on confidentiality, integrity and availability is high, but delivery requirements - not exploitability - bound the practical risk, and no public exploit or active exploitation is identified in the available data. The upstream project has published a fix that removes pickle auto-detection.

RemediationAI

Apply the upstream fix from https://github.com/ehpor/hcipy/pull/424, merged as commit ce3e08a85af8d3f43dae02e01c30b3231495e763; no tagged release version containing the change is independently confirmed in the available data, so pin the commit or a later release once published. After the fix, pickle is no longer auto-detected from the file extension - _guess_file_format raises ValueError and callers must pass fmt='pickle' explicitly, which also emits a DeprecationWarning at read and write time. Migrate stored artifacts (pupils, apodizers, PSFs, mode bases) to the asdf or fits formats that the advisory and patch recommend, and re-save any existing .pkl assets under those formats rather than re-reading them. For installations that cannot yet update, treat .pkl/.pickle files as executable content: never pass a path supplied by an attacker or downloaded from an untrusted source to read_field, read_grid or read_mode_basis, since these functions deserialize based on the extension without asking, and restrict such files to a trusted, integrity-checked directory in the processing pipeline. Be aware that the upstream change is an opt-in gate rather than a removal of pickle.load: explicitly requesting fmt='pickle' still deserializes arbitrary pickles and remains unsafe for untrusted input, so the deprecation warning should be treated as a migration deadline, not a hard block. Given the 'this_week' priority label, schedule the update in the current patch cycle rather than deferring it.

Affected VersionsENISA

HCIPy 0 ≤0.7.1

Affected Packages

euvd hcipy no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

HCIPy is a Python library for high-contrast imaging simulation (wavefront sensing, coronagraph and pupil/apodizer/PSF modeling). Its hcipy/util/io.py implements generic serialization helpers - read_field, write_field, read_grid, write_grid, read_mode_basis, write_mode_basis - that infer the file format from the filename via an internal _guess_file_format routine and then dispatch to the appropriate reader. Through version 0.7.1 that routine returned 'pickle' for .pkl/.pickle extensions, and the read paths passed the file handle directly to pickle.load (source lines 262-264 in v0.7.1). This is the classic CWE-502 unsafe deserialization pattern: Python's pickle format is not a data-only format, it invokes constructors, and the __reduce__ protocol lets an attacker specify an arbitrary callable and arguments that are executed during unpickling, before any validation of the resulting object can occur. Because the format selection is automatic and triggered purely by the file extension, a caller who simply invokes read_field('input.pkl') gets code execution with no further interaction. The vulnerable objects are the ones HCIPy persists this way: pupils, apodizers, PSFs and mode bases. The upstream fix in PR #424 changes _guess_file_format to raise ValueError for pickle extensions (pickle is no longer auto-detected and must be requested with an explicit fmt='pickle'), and adds DeprecationWarning-emitting helpers on the pickle read and write paths that advise migrating to the asdf or fits formats; the tests were updated to pass the format explicitly. Notably, the fix is an opt-in gate and warning rather than removal of pickle.load, so explicitly requesting fmt='pickle' still deserializes arbitrary pickles.

Know when Hcipy gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 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:N
vuln.today AI 7.8 HIGH

Local because the attacker-supplied file must be opened by the victim (AV:L, UI:R); no privileges needed to call the read function (PR:N); arbitrary code execution yields full C/I/A impact in the user's scope.

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
4.0 AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

HCIPy through 0.7.1 contains an insecure deserialization vulnerability that allows attackers to execute code by supplying crafted .pkl files to read_field, read_grid or read_mode_basis. Because hcipy/util/io.py selects pickle by file extension and calls pickle.load, a __reduce__ gadget in a pupil, apodizer, PSF or mode-basis file runs code with the user's privileges.

Executive ViewAI

Why It Matters

A high-severity vulnerability in the HCIPy optical simulation library (up to version 0.7.1) allows an attacker to execute arbitrary code on a user's system if the user opens a maliciously crafted .pkl file through the library's read_field, read_grid, or read_mode_basis functions. Although passive user interaction is required - an attacker must first deliver the file - successful exploitation could lead to full system compromise with high impact on confidentiality, integrity, and availability. Leadership should care because researchers and engineers using HCIPy may be targeted via phishing or shared data repositories, potentially exposing sensitive intellectual property or research infrastructure.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.3%
Top 89% exploitable
Prevalence
Low
niche high-contrast-imaging scientific Python library, astronomy-research footprint only
Social Media
3
Sightings
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact
High

Priority Score

42
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +42
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Insecure deserialization occurs when an application converts serialized data (a stream of bytes representing an object's state) back into a living object without proper validation.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy