Back to skill

Security audit

Bitchat

Security checks for vulnerabilities and agentic risk

Overview

This Bitchat skill appears purpose-built for mesh messaging, but it exposes unauthenticated message injection into OpenClaw sessions and understates that risk.

Install only if you can keep the OpenClaw webhook and bitchat-node bridge bound to trusted local interfaces, change dmPolicy to allowlist or disabled, and understand that nearby peers or reachable HTTP callers may inject text into active agent sessions. Avoid remote bridgeUrl values unless you add transport security and bridge authentication.

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
src/index.ts:224
Finding

Unauthenticated Webhook Allows Forged Messages to Be Injected into OpenClaw Sessions

Content
View full analysis
{ try { const body = req.body as BitchatInboundMessage; if (!body || !body.senderPeerID || !body.text) { res.status(400).json({ error: 'Invalid message format' }); return; } const cfg = api.config as Record; const config = resolveConfig(cfg); if (!isSenderAllowed(config, body.senderPeerID)) { res.status(403).json({ error: 'Sender not allowed' }); return; } await api.injectMessage({ channel: 'bitchat', senderId: body.senderPeerID, senderName: body.senderNickname, text: body.text, messageId: body.messageId, chatType: body.type === 'direct' ? 'direct' : 'group', timestamp: body.timestamp, }); res.json({ ok: true }); } catch (err) { logger.error('[bitchat] Webhook error:', err); res.status(500).json({ error: 'Internal error' }); } }, }); ``` The default policy also accepts every supplied peer identifier: ```ts const DEFAULT_CONFIG: Required = { enabled: true, nickname: 'openclaw', bridgeUrl: 'http://localhost:3939', webhookPath: '/bitchat-webhook', autoStart: false, dmPolicy: 'open', allowFrom: [], }; ``` ### Technical Analysis The webhook accepts attacker-controlled message objects and passes their contents directly to `api.injectMessage`. It does not authenticate the bridge, verify a message signature, validate an authorization token, restrict the request origin, or provide replay protection. The limited validation only establishes that `senderPeerID` and `text` are truthy. It does not prove that the request came from ...[truncated 2379 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
src/bridge.ts:40
Finding

Unrestricted Bridge URL Can Disclose Messages and Access Arbitrary HTTP Services

Content
View full analysis
{ const response = await fetch(`${this.bridgeUrl}/api/status`); if (!response.ok) { throw new Error(`Bridge status failed: ${response.status}`); } return response.json() as Promise; } async sendPublicMessage(text: string): Promise { const response = await fetch(`${this.bridgeUrl}/api/send`, { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ type: 'public', text }), }); if (!response.ok) { const error = await response.text(); throw new Error(`Failed to send public message: ${error}`); } } async sendDirectMessage(recipientPeerID: string, text: string): Promise { const response = await fetch(`${this.bridgeUrl}/api/send`, { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ type: 'direct', recipientPeerID, text }), }); if (!response.ok) { const error = await response.text(); throw new Error(`Failed to send direct message: ${error}`); } } async getPeers(): Promise<{ peerID: string; nickname: string; lastSeen: number }[]> { const response = await fetch(`${this.bridgeUrl}/api/peers`); if (!response.ok) { throw new Error(` ...[truncated 4265 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (16)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

A description-behavior mismatch is dangerous because it can mislead reviewers and users about what the skill actually does, especially when the implemented surface is more generic and powerful than a narrowly described Bitchat integration. Generic plugin, gateway, outbound messaging, or HTTP abstractions can create hidden expansion points for unexpected network behavior, data exfiltration, or later feature abuse under a trusted label.

Content

No source excerpt is available for this finding.

Known Vulnerable Dependency: @hono/node-server==1.19.9 — 3 advisory(ies): CVE-2026-39406 (@hono/node-server: Middleware bypass via repeated slashes in serveStatic); GHSA-frvp-7c67-39w9 (Node.js Adapter for Hono: Path traversal in `serve-static` on Windows via encode); CVE-2026-29087 (@hono/node-server has authorization bypass for protected static paths via encode)

High
Category
Supply Chain
Confidence
92% confidence
Finding

The lockfile includes @hono/node-server 1.19.9, and the cited advisories describe path traversal and authorization-bypass issues in static file serving. Even though this package is marked optional/peer and may not be exercised by this specific skill, its presence in the dependency graph means a vulnerable component can be installed and used in the OpenClaw environment, which is a real supply-chain risk.

Content

No source excerpt is available for this finding.

Known Vulnerable Dependency: @mariozechner/pi-coding-agent==0.51.1 — 3 advisory(ies): CVE-2026-54326 (Pi Agent: Potential XSS in HTML session exports via Markdown URL sanitization by); CVE-2026-54328 (Pi Agent: Predictable temporary extension install paths allow local privilege es); CVE-2026-54327 (Pi Agent: Race condition in Pi auth.json writes could expose stored credentials)

High
Category
Supply Chain
Confidence
86% confidence
Finding

The lockfile pins @mariozechner/pi-coding-agent 0.51.1, which is reported vulnerable to XSS in exported HTML, predictable temporary extension paths, and credential-exposing race conditions. In an agent ecosystem, a coding-agent package is especially sensitive because it may handle session data, credentials, and local filesystem operations, increasing the chance that these flaws matter if the package is present or invoked.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The webhook handler accepts arbitrary POST requests containing senderPeerID and text, then directly injects them into the agent without any authentication, signature validation, shared secret, or origin/IP verification. An attacker who can reach this endpoint can spoof messages from any peer ID and drive agent actions or prompt injection through a simple HTTP call.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

Using dmPolicy: "open" as the example/default normalizes acceptance of messages from any nearby peer without emphasizing the security implications. For an agent integration skill, this substantially increases the chance that arbitrary local adversaries can inject prompts, trigger workflows, or manipulate sessions over BLE proximity alone.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The README describes incoming messages being routed into active OpenClaw AI sessions without prominently warning that nearby BLE peers can become prompt sources for the agent. In this skill context, untrusted external messages can directly influence agent behavior, creating a prompt-injection and unauthorized task-triggering path.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The README states communication is 'local-only' and implies nothing leaves the BLE mesh, but the documented architecture clearly includes an HTTP bridge and webhook interface. That mismatch can cause operators to underestimate exposure and deploy the bridge insecurely, especially if it binds beyond localhost or accepts webhook traffic from other hosts.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · README.md (reported line 330)May include surrounding context.

Message delivery failures:

bash
# Check peer connectivity
curl http://localhost:3939/api/peers

# Test direct message
curl -X POST http://localhost:3939/api/send \

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
82% confidence
Finding

The skill advertises network-capable behavior but does not declare any explicit tool scope such as permissions or allowed-tools. In an agent ecosystem, missing capability declarations weaken review and policy enforcement, making it easier for a skill to obtain or exercise network access without clear operator awareness.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The method registers a webhook by POSTing the provided URL to the bridge service, which is a network operation that shares potentially sensitive endpoint information. While the code has a brief technical doc comment, it does not provide a user-facing warning, confirmation, or visible disclosure about transmitting this data.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The plugin exposes a POST webhook that accepts inbound messages and forwards them into OpenClaw via api.injectMessage, which expands the skill's effective trust boundary beyond BLE mesh integration into generic HTTP-triggered message injection. Even if intended as a bridge endpoint, the manifest/description does not make that broader capability clear, so external HTTP callers can influence agent behavior through an interface not obviously implied by a simple channel plugin.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

External content received over HTTP is injected into the agent as chat messages with no user-facing disclosure that the source is an unauthenticated webhook rather than a verified Bitchat peer. This increases the risk of social engineering and prompt-injection because operators or downstream logic may treat the content as trusted channel input when it is actually attacker-supplied HTTP data.

Content

No source excerpt is available for this finding.

Known Vulnerable Dependency: @protobufjs/utf8==1.1.0 — 1 advisory(ies): CVE-2026-44288 (protobufjs has overlong UTF-8 decoding)

Low
Category
Supply Chain
Confidence
75% confidence
Finding

@protobufjs/utf8 1.1.0 is present and the advisory indicates improper acceptance of overlong UTF-8 encodings. This is a real issue, but by itself it is typically lower severity and usually becomes meaningful only when malformed UTF-8 can bypass validation or canonicalization checks in higher-level protocol handling.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependencies lack version pinning, allowing potential malicious package updates. Consider pinning versions.

Content

Scanner excerpt · package.json (reported line 38)May include surrounding context.

json
"prepublishOnly": "npm run build"
  },
  "dependencies": {
    "bitchat-node": "^0.1.0"
  },
  "peerDependencies": {
    "openclaw": ">=2026.1.0"

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependencies lack version pinning, allowing potential malicious package updates. Consider pinning versions.

Content

Scanner excerpt · package.json (reported line 44)May include surrounding context.

json
"openclaw": ">=2026.1.0"
  },
  "devDependencies": {
    "@types/node": "^20.10.0",
    "typescript": "^5.3.0"
  },
  "repository": {

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependencies lack version pinning, allowing potential malicious package updates. Consider pinning versions.

Content

Scanner excerpt · package.json (reported line 45)May include surrounding context.

json
},
  "devDependencies": {
    "@types/node": "^20.10.0",
    "typescript": "^5.3.0"
  },
  "repository": {
    "type": "git",

Static analysis

No suspicious patterns detected.