CVE-2026-102734
Deferred Deferred - Pending Action

asteval Interpreter Memory Corruption via ctypes Access

Vulnerability report for CVE-2026-102734, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-10-13

Last updated on: 2026-10-16

Assigner: GitHub, Inc.

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.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-10-13
Last Modified
2026-10-16
Generated
2026-10-19
AI Q&A
2026-10-13
EPSS Evaluated
2026-10-18
NVD
EUVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
lmfit asteval < 1.0.9

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-749 The product provides an Applications Programming Interface (API) or similar interface for interaction with external actors, but the interface includes a dangerous method or function that is not properly restricted.
CWE-693 The product does not use or incorrectly uses a protection mechanism that provides sufficient defense against directed attacks against the product.
CWE-913 The product does not properly restrict reading from or writing to dynamically-managed code resources such as variables, objects, classes, attributes, functions, or executable instructions or statements.

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

This is a sandbox escape vulnerability in the asteval library (versions <= 1.0.8) that allows arbitrary native memory read and write operations when numpy is installed. The default interpreter configuration fails to restrict access to ctypes type objects and their methods like from_address, which can be reached through numpy's ndarray.ctypes wrapper. An attacker can craft expressions to read or write memory at arbitrary addresses, enabling code execution, memory corruption, or denial of service.

Detection Guidance

Check if asteval version is <= 1.0.8 by running: pip show asteval. If numpy is installed alongside vulnerable asteval, the system is at risk. Inspect applications using asteval for untrusted input evaluation with numpy enabled.

Impact Analysis

If you use asteval to evaluate untrusted input with numpy installed, an attacker could exploit this to read or corrupt arbitrary process memory, escape the sandbox, execute code, disclose secrets, or crash the host process. This could lead to data breaches, system compromise, or service disruption.

Compliance Impact

This vulnerability could lead to unauthorized data access or disclosure, violating GDPR's data protection requirements and HIPAA's safeguards for protected health information. Organizations using affected versions may face compliance violations, legal penalties, and reputational damage due to potential data breaches.

Mitigation Strategies

Upgrade asteval to version 1.0.9 or later using: pip install --upgrade asteval. If upgrading is not possible, construct the interpreter with use_numpy=False to disable numpy support.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-102734. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart