Back to skill

Security audit

hermes multiagent skill

Security checks for vulnerabilities and agentic risk

Overview

This skill is not clearly malicious, but its message router can mix or disrupt messages between agents, so it should be reviewed before use.

Use this only for testing or non-sensitive agent coordination unless the routing bugs are fixed. Before production use, require immutable or copied messages, recycle only after all handlers finish, reject duplicate active agent IDs or isolate them by session, and document the Chinese-only user-facing text. I found no evidence of network exfiltration, credential access, shell execution, or persistent backdoors.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T09 · Insecure Skill Coding Practices

Error
Location
hermes.py:43
Finding

Premature Recycling of Mutable Messages Causes Cross-Delivery Data Corruption

Content
View full analysis
int: with self.lock: subscribers = dict(self.subscribers) if msg.from_agent in subscribers: del subscribers[msg.from_agent] count = len(subscribers) for agent_id, handler in subscribers.items(): executor.submit(handler, msg) return count ``` ```python msg = self._acquire_message(topic, from_agent, session_id, payload, trace_id) delivered = synapse.deliver(msg, self._executor) with self._global_lock: self._stats["total_delivered"] += delivered self._executor.submit(self._safe_release, msg) return delivered ``` ### Technical Analysis The router passes the same mutable `HermesMessage` instance to every asynchronous subscriber handler. Immediately after queuing the handlers, it queues `_safe_release`, which returns that message to the reusable object pool. Although the release task is submitted after the handler tasks, `ThreadPoolExecutor` does not guarantee that all previously submitted handlers have completed before another worker executes the release task. For example, one subscriber may block while another worker reaches `_safe_release`. Once the message is returned to the pool, a later call to `_acquire_message` can obtain and overwrite the object’s `topic`, `from_agent`, `session_id`, `payload`, `trace_id`, and `sent_at` fields while the earlier subscriber still holds a reference to it. This creates a time-of-check/time-of-use race over shared mutable state. A subscriber authorized to receive one publication may observe fields or payload data belonging to a different publication. ### Attack Path 1. An attacker controls or influences a subscribed message handler. 2. The handler deliberately blocks or delays before re ...[truncated 1303 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
hermes_sessions_integration.py:71
Finding

Duplicate Agent IDs Allow Cross-Session Subscription Removal and Handler Replacement

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (7)

Tp2

High
Category
MCP Tool Poisoning
Confidence
85% confidence
Finding

Mixing characters from multiple Unicode scripts in a single identifier is a common technique to create visually ambiguous tool names.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
86% confidence
Finding

描述强调的是一种高性能、多智能体通信调度/优化能力,侧重点是‘毫秒级分发’、‘精准对齐’、‘100 个 Agent 协同降本’这类调度性能与协同优化效果。但代码并未体现任何明确的调度算法、负载均衡、优先级排序、通信成本优化、批处理、性能控制或大规模协同策略。实际代码更像是一个消息总线集成与订阅管理组件:负责 agent 注册、topic 订阅、任务消息发布、done/system 事件转发、退出清理和简单统计。虽然它与多智能体通信有关,属于相关基础设施,但其主要目的与描述中的“通信调度优化器”不一致,且新增了生命周期管理、pending task 跟踪等未在描述中体现的核心能力。因此应判定为描述与实际行为存在实质性不匹配。

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest fields and the full skill documentation are presented only in Chinese, which effectively forces a specific language on users. The policy allows locale constraints only when they are explicitly justified or when users are offered a language choice, neither of which appears here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

This Python file contains natural-language descriptions and console output in Chinese, but there is no indication that the skill is region-specific or that users can opt into another language. Under the policy, forcing a specific language without user choice is a locale-policy violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
93% confidence
Finding

The only natural-language description in this file is written entirely in Chinese, with no indication that other languages are supported or that the locale is optional. Under the policy, forcing a specific language without user opt-in is a natural-language locale violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

The main demonstration block prints status and results exclusively in Chinese, which enforces a specific language for runtime output. Because no language selection or justification is present, this conflicts with the natural-language locale policy.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
98% confidence
Finding

The module docstring is entirely in Chinese, and the script's demonstration output is also Chinese-only. This imposes a specific language on users without any indication of locale selection or documented justification, which matches the language-policy violation criterion.

Content

No source excerpt is available for this finding.