CVE-2026-9367: NousResearch hermes-agent terminal_tool approval.py detect_dangerous_command os command injection
A vulnerability was determined in NousResearch hermes-agent up to 5157f5427f19488b31c6fdebbacd15d798ce7f63. This affects the function detectdangerouscommand of the file tools/approval.py of the component terminaltool. This manipulation causes os command injection. It is possible to initiate the attack remotely. The exploit has been publicly disclosed and may be utilized. The vendor was contacted early about this disclosure but did not respond in any way.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Remove
Remove
NousResearch/hermes-agentfrom your environment.Uninstall NousResearch hermes-agent from affected systems (or remove the terminal_tool component) if the agent is not required.
- Configuration
Disable the terminal_tool component or prevent execution of tools/approval.py (remove/rename the file or adjust permissions) to stop use of detect_dangerous_command.
NousResearch hermes-agent (terminal_tool - tools/approval.py) terminal_tool enabled = false - Compensating control
Prevent remote exploitation by restricting network access to hosts running hermes-agent: block or limit agent management/agent ports to trusted IPs, place hosts behind a firewall/ACL, or isolate them on a restricted network segment.
- Operational
Investigate systems for signs of exploitation (since the exploit is publicly disclosed). If compromise is suspected, follow incident response procedures (isolate affected hosts, perform forensic analysis, remediate or rebuild, and monitor for further activity).
Event History
Frequently Asked Questions
What is the severity of CVE-2026-9367?
The severity of CVE-2026-9367 is rated as high with a score of 7.3.
How do I fix CVE-2026-9367?
To fix CVE-2026-9367, ensure you update to the latest version of NousResearch hermes-agent that addresses the os command injection vulnerability.
What component is affected by CVE-2026-9367?
CVE-2026-9367 affects the detect_dangerous_command function in the approval.py file of the NousResearch hermes-agent terminal_tool component.
What type of vulnerability is CVE-2026-9367?
CVE-2026-9367 is classified as an OS Command Injection vulnerability.
What can attackers do with CVE-2026-9367?
Attackers can exploit CVE-2026-9367 to execute arbitrary commands on the server through the vulnerable detect_dangerous_command function.