Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend crafted request to hermes-agent
-
DeliveryReach _scan_context_content function
-
ExploitInject malicious payload
-
ExecutionExecute arbitrary code
-
ImpactAchieve partial system impact
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Input neutralization, injection prevention
|
| Exploitation Conditions | No special conditions - remote unauthenticated exploitation against default configurations of hermes-agent. The vulnerability requires only that the hermes-agent service is network-accessible and processes user input through the affected _scan_context_content function. No authentication, special configuration, or user interaction is required based on the CVSS vector PR:N/UI:N. |
| Impact | The CVSS 3.1 score of 7.3 reflects a high-severity vulnerability with network attack vector, low complexity, and no required privileges or user interaction. The CVSS E:P metric confirms proof-of-concept code exists, which aligns with the public exploit on GitHub. However, there's no CISA KEV listing indicating active exploitation in the wild. The combination of remote unauthenticated access and available exploit code makes this a priority for organizations using hermes-agent, though the limited impact ratings (C:L/I:L/A:L) suggest partial rather than complete system compromise. The vendor's lack of response (RL:X) increases risk as no official patch timeline exists. |
| Exploit ScenarioDerived | An attacker sends specially crafted input to a hermes-agent instance exposed to the network. The malicious payload reaches the _scan_context_content function in prompt_builder.py without proper sanitization, allowing the attacker to inject and execute arbitrary code within the application context. Public exploit code at https://gist.github.com/YLChen-007/581fd92de5548fbaacb2092e848a75cc demonstrates the attack methodology. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 24, 2026
Code injection in NousResearch hermes-agent 2026.4.23 allows remote unauthenticated attackers to inject and execute arbitrary code through the _scan_context_content function in agent/prompt_builder.py. The vulnerability has publicly available exploit code and affects all versions up to 2026.4.23, with the vendor failing to respond to disclosure attempts.
RemediationAI
No vendor-released patch identified at time of analysis due to vendor non-response. Organizations should immediately review usage of the _scan_context_content function and implement input validation for any data passed to this function. Consider temporarily disabling or restricting access to functionality that uses prompt_builder.py until a patch is available. Monitor the VulDB references at https://vuldb.com/vuln/365329 for updates. As a compensating control, implement web application firewall rules to filter potentially malicious input patterns targeting this injection vulnerability, though this may impact legitimate functionality.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in pypi
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The vulnerability exists in the _scan_context_content function within the prompt_builder.py module of hermes-agent, a NousResearch product. The issue is classified as CWE-74 (Improper Neutralization of Special Elements in Output Used by a Downstream Component), indicating that user-controlled input is not properly sanitized before being used in a way that allows injection attacks. The CPE string indicates all versions of hermes-agent are affected.
Know when Hermes Agent 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
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:P
Primary rating from Vendor (VulDB) · only source for this CVE.
CVSS VectorVendor: VulDB
Lifecycle Timeline
2DescriptionCVE.org
A vulnerability was found in NousResearch hermes-agent 2026.4.23. The impacted element is the function _scan_context_content of the file agent/prompt_builder.py. The manipulation results in injection. The attack may be performed from remote. The exploit has been made public and could be used. The vendor was contacted early about this disclosure but did not respond in any way.
Executive ViewAI
NousResearch hermes-agent versions up to 2026.4.23 contain an unauthenticated remote code execution vulnerability in the context scanning function that allows attackers to execute arbitrary code on affected systems. This poses an immediate threat to any organization deploying this agent component, as publicly available exploit code exists and the vendor has not released a patch despite disclosure attempts.
No vendor-released patch identified at time of analysis. Interim mitigations: (1) Restrict network access to hermes-agent endpoints using firewall rules and IP allowlisting; (2) Disable or remove the _scan_context_content function if not operationally required; (3) Implement Web Application Firewall rules to detect code injection patterns in requests to agent/prompt_builder.py endpoints; (4) Run hermes-agent in a sandboxed environment with minimal system privileges and limited outbound network access; (5) Monitor for suspicious execution patterns or unexpected child processes spawned by the agent service.
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.
More in Hermes Agent
View allRemote code execution in NousResearch Hermes Agent 0.18.2-0.21.0 allows an unauthenticated attacker to execute arbitrary
Remote command injection in NousResearch hermes-agent allows unauthenticated attackers to execute arbitrary OS commands
Path traversal in NousResearch hermes-agent (all versions through 2026.5.16) exposes arbitrary server-side files via the
Path traversal in NousResearch hermes-agent through version 2026.4.16 allows remote unauthenticated attackers to bypass
Remote sandbox escape in NousResearch hermes-agent versions up to 2026.4.16 allows unauthenticated attackers to manipula
Path traversal in NousResearch hermes-agent 0.8.0 exposes arbitrary server-side files to unauthenticated remote attacker
Remote code/prompt injection in NousResearch Hermes Agent through 0.12.0 stems from improper neutralization in the _comp
Remote injection in NousResearch Hermes Agent through version 2026.4.30 allows unauthenticated attackers to manipulate t
Improper output escaping in NousResearch Hermes Agent versions up to 2026.4.16 allows remote unauthenticated attackers t
Remote injection vulnerability in NousResearch hermes-agent versions up to 2026.4.23 enables unauthenticated attackers t
Uncontrolled resource consumption in NousResearch hermes-agent (all versions through 2026.4.30) allows remote unauthenti
Missing authorization in NousResearch hermes-agent versions up to 2026.4.16 allows remote attackers to bypass authentica
EUVD-2026-31580
GHSA-pgp4-xr4j-h5cg
NVD
CVE.org
EPSS
VulDB
Exploit-DB