CVE-2026-102734 asteval sandbox escape: arbitrary native memory read/write via numpy ctypes in default asteval Interpreter

Medium 5.5 Published Updated

Attackers can escape the asteval sandbox to read/write arbitrary memory and execute code via numpy ctypes in the default interpreter.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Local or same network only
Victim action needed
A user has to click or open something
Fix
None listed

What is CVE-2026-102734?

CVE-2026-102734 is a medium-severity code injection vulnerability in lmfit asteval, published on 13 Oct 2026. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

Official description

asteval is a Python expression evaluator designed for restricted execution. Prior to 1.0.9, in asteval/astutils.py, the default Interpreter with numpy enabled exposes a ctypes type and permits from_address memory access. safe_getattr blocks the ctypes module but not reachable ctypes type objects, while attribute assignments use unfiltered setattr instead of safe_setattr. An attacker-controlled expression can derive an address with id, read memory through from_address, and write through an attribute assignment. The expression can read or corrupt arbitrary process memory, escape the intended sandbox, execute code, disclose secrets, or crash the host process. This issue is fixed in version 1.0.9.

Weakness: CWE-913, CWE-749, CWE-693

Which versions are affected by CVE-2026-102734?

2 open source packages ship an affected version, including asteval.

PackageAffectedFixed in
asteval PyPIAll versions1.0.9
asteval PyPIAll versions1.0.9

How do I fix CVE-2026-102734?

Upgrade asteval to 1.0.9 or later.

Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.

Is CVE-2026-102734 being exploited?

There is no known exploitation of CVE-2026-102734 in the wild and no public exploit code.

Sources

Also known as DEBIAN-CVE-2026-102734, GHSA-9w56-46f6-3qhx, UBUNTU-CVE-2026-102734.

Is CVE-2026-102734 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free