Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend POST to notebook API
-
DeliveryInject Python payload
-
ExploitServer executes via exec()
-
ExecutionArbitrary code runs as server
-
ImpactSystem compromised
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
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 | No special conditions - remote unauthenticated exploitation against default configurations of Cognee. The notebook cell execution API endpoint must be network-accessible, which appears to be the default deployment mode based on the vulnerability description. No authentication, special configuration, or user interaction is required. The only limiting factor is network accessibility to the API endpoint. |
| Impact | The CVSS 9.8 score accurately reflects the technical severity: network-accessible (AV:N), low complexity (AC:L), no authentication required (PR:N), and no user interaction (UI:N) with high impact to confidentiality, integrity, and availability. However, the EPSS score of 0.06% (18th percentile) suggests low real-world exploitation probability, potentially due to limited deployment of Cognee. The SSVC framework confirms this is automatable with total technical impact but notes no current exploitation. The disconnect between high CVSS and low EPSS likely indicates this is a severe vulnerability in a niche product rather than a widespread threat. No public exploit code has been identified, and the vulnerability is not listed in CISA KEV, confirming no known active exploitation. |
| Exploit ScenarioDerived | An attacker identifies a Cognee instance with exposed API endpoints through scanning or documentation. They send a crafted POST request to the notebook execution endpoint containing Python code like 'import os; os.system("reverse shell command")'. The server executes this code directly via exec(), establishing remote access with server process privileges. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 15, 2026
Remote code execution in Cognee v0.4.0 and earlier allows unauthenticated attackers to execute arbitrary Python code via the notebook cell execution API endpoint. The vulnerability stems from unsafe use of Python's exec() function without sandboxing or validation, enabling complete system compromise with server process privileges. While not actively exploited (not in KEV), the vulnerability is automatable with total technical impact per SSVC framework, though EPSS indicates low exploitation probability at 0.06%.
RemediationAI
No vendor-released patch identified at time of analysis. The Notion page reference (https://www.notion.so/CVE-2026-31231-35d1e13931888178a963ef9efeb29113) may contain additional details but requires access verification. Until a patch is available, disable the notebook cell execution API endpoint entirely if not required for core functionality. If the endpoint must remain active, implement API authentication using strong tokens or certificates, restrict access via firewall rules to trusted IP ranges only, and consider deploying a Python sandboxing solution like RestrictedPython or running the execution in isolated containers with limited privileges. Each mitigation has trade-offs: disabling the endpoint breaks notebook functionality, authentication adds complexity, and sandboxing may limit legitimate code execution capabilities.
Affected VersionsENISA
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Cognee's notebook cell execution API is designed to dynamically execute Python code, likely for interactive data processing or analysis workflows. The vulnerability is classified as CWE-94 (Improper Control of Generation of Code), where user-supplied Python code is passed directly to the exec() function without security controls. This design pattern is inherently dangerous as Python's exec() provides full access to the interpreter environment, including system calls, file operations, and network access. The CPE data shows incomplete product identification, suggesting this may be a newer or less mainstream project.
Know when Python 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
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Primary rating from Vendor (mitre) · only source for this CVE.
CVSS VectorVendor: mitre
Lifecycle Timeline
2DescriptionCVE.org
Cognee thru v0.4.0 contains a critical remote code execution vulnerability in its notebook cell execution API endpoint. The endpoint is designed to execute arbitrary Python code provided by the user, but it does so using the unsafe exec() function without any sandboxing, validation, or security controls. An attacker can exploit this by sending a specially crafted POST request containing malicious Python code to the execution endpoint. This leads to arbitrary code execution on the Cognee server with the privileges of the server process, allowing complete compromise of the system.
Executive ViewAI
Cognee v0.4.0 and earlier contains a critical remote code execution vulnerability allowing unauthenticated attackers to execute arbitrary code on affected servers, potentially compromising all data and systems the application can access. Organizations using Cognee must immediately isolate affected instances or discontinue use until a patched version is available, as the vulnerability requires no authentication and carries a 9.8 CVSS score despite current low exploitation probability.
No vendor-released patch identified at time of analysis. Interim mitigations: (1) Disable or isolate Cognee notebook cell execution API endpoint from untrusted networks; (2) Implement network segmentation restricting Cognee server access to authenticated internal users only; (3) Run Cognee in a containerized environment with minimal host privileges and resource limits; (4) Monitor all Cognee process execution and API calls for anomalous activity; (5) Evaluate replacement of Cognee with sandboxed or vendor-supported alternatives pending patch availability.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t
BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser
pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi
The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python
BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica
OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph
pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.
Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301
In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse
Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to
Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/
pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne
EUVD-2026-29554
GHSA-fcch-9ph8-q3p4
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB