Summary
A code injection vulnerability in Aeon's load_human_activity_segmentation_datasets method fails to properly validate a user-supplied string before using it as Python code. If a user visits a malicious page or opens a malicious file that reaches the vulnerable method, an attacker may execute arbitrary code in the context of the current process.
Affected context
The vulnerability occurs in Aeon installations that use the load_human_activity_segmentation_datasets method to process activity-segmentation dataset information. Risk depends on whether attacker-controlled content can influence the method's user-supplied string and whether a user is induced to visit malicious content or open a malicious file that triggers the vulnerable code path.
Exploit preconditions
- Attack surface: The Aeon dataset-loading API and any application workflow that invokes it
- Required access: The attacker generally does not need direct access to the target process, but must deliver or control input consumed by the method
- User interaction: A user must visit a malicious page or open a malicious file
- Trigger point: Processing the attacker-influenced string in
load_human_activity_segmentation_datasets - Why exploitation is possible: The input is insufficiently validated before being used in a Python code-execution context
Why this happens
The underlying bug is the use of a user-influenced string in a dynamic Python execution path without adequate validation or confinement. This allows data that should be treated as inert input to affect program behavior as executable code. The pattern maps to CWE-94: Improper Control of Generation of Code, because externally influenced data can alter or inject code executed by the application.
Potential impact
- An attacker may execute arbitrary Python code in the current process
- The attacker could access data available to the process
- The process may be altered, disrupted, or used to affect downstream workflows
- Compromise could extend to other resources available through the process's privileges
General mitigation guidance
Mitigation generally focuses on removing dynamic code execution from dataset-loading paths and treating all externally influenced strings as untrusted data.
Common defensive patterns include:
- Replacing dynamic evaluation or code-generation behavior with explicit parsing and bounded data structures
- Applying allowlisted formats, values, and types before processing dataset parameters
- Separating data interpretation from executable logic
- Requiring explicit user confirmation for untrusted files or content that can invoke dataset-loading workflows
- Running the affected process with least privilege and limiting access to sensitive resources
- Using isolation controls to reduce the consequences of code execution
How teams detect issues like this
Organizations can look for this weakness through:
- Static analysis rules identifying
eval,exec, dynamic compilation, or equivalent code-generation paths receiving external input - Code review checks for user-supplied strings passed into interpreters, command builders, or dynamic import mechanisms
- Tests using unexpected dataset names, metadata, and file content to verify that input remains data rather than executable logic
- Policy enforcement requiring allowlisted schemas and rejecting dynamic evaluation in data-processing components
- Runtime monitoring for unusual child processes, file access, or network activity from Aeon processes
Automated security review tools may help identify dynamic execution patterns, but findings should be validated against the application's actual data flow.

