Back to skill

Security audit

AI浏览器WebSocket控制

Security checks for vulnerabilities and agentic risk

Overview

This skill is a real browser remote-control server, but it exposes too much unauthenticated control and page data without clear guardrails.

Install only in an isolated environment, bound to localhost or otherwise access-controlled, and avoid using it with sensitive logged-in accounts. Treat screenshots, DOM snapshots, typed text, and evaluate scripts as potentially exposing private data or performing real website actions.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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
Findings (4)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
server.js:86
Finding

Unauthenticated WebSocket API Permits Complete Browser Control and Arbitrary Page-Context JavaScript

Content
View full analysis
{ console.log('🔌 新的客户端连接'); ws.on('message', async (message) => { try { const { action, params, id } = JSON.parse(message); console.log(`⚡ 收到指令:${action}`, params); if (!browser) await initBrowser(); if (!page) page = await browser.newPage(); if (params.targetId) { // 简单处理:如果有 targetId 且不是当前页,尝试切换(简化版暂不实现多 Tab 切换逻辑,默认单页) // 实际使用中,可以扩展为多 page 管理 } const result = await handleAction(action, params || {}); ws.send(JSON.stringify({ id, success: true, result })); } catch (error) { console.error('❌ 执行错误:', error); ws.send(JSON.stringify({ id: JSON.parse(message).id, success: false, error: error.message })); } }); ws.on('close', () => { console.log('🔌 客户端断开连接'); }); }); ``` ### Technical Analysis The WebSocket server accepts connections without authenticating the client, checking authorization, or validating the WebSocket `Origin` header. Constructing `WebSocket.Server` with only a port does not explicitly restrict the listener to the loopback interface, despite the documentation presenting the service as a localhost endpoint. Every connected client receives access to the same shared Chromium instance and page. Available actions include navigation, screenshots, DOM extraction, clicking, typing, and `ev ...[truncated 1883 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
server.js:47
Finding

Unrestricted Navigation Enables Browser-Based Server-Side Request Forgery

Content
View full analysis
Remediation
View remediation

T05 · Unauthorized Access and Privilege Escalation

Warning
Location
server.js:18
Finding

Chromium Process Is Launched Without Its Security Sandbox

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
server.js:94
Finding

Browser Input Including Credentials Is Logged in Plaintext

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • 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
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (20)

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The skill documentation omits or understates high-risk functionality such as arbitrary page-script execution via evaluate, while also overstating support for configurable headless/headful modes and auto-reconnect. Undisclosed script execution is especially risky because it can inspect page state, manipulate authenticated sessions, and trigger sensitive actions in the browser context.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill documentation omits or understates high-risk functionality such as arbitrary page-script execution via evaluate, while also overstating support for configurable headless/headful modes and auto-reconnect. Undisclosed script execution is especially risky because it can inspect page state, manipulate authenticated sessions, and trigger sensitive actions in the browser context.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The WebSocket API exposes an 'evaluate' action that passes attacker-controlled JavaScript directly into page.evaluate(), allowing any connected client to execute arbitrary code in the browser context of whatever page is open. In this skill, that can read DOM contents, interact with authenticated sessions, and trigger privileged actions on sites the browser has loaded, which is broader and riskier than normal fixed-function browser automation.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

WebSocket messages can invoke arbitrary page script execution with no authentication, consent prompt, or user-facing warning. In a real browser context, this allows a connected client to silently inspect content, manipulate pages, and perform actions using any active authenticated session in the browser.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
83% confidence
Finding

The skill exposes browser automation capabilities and references environment-variable configuration, but it does not declare any explicit tool scope or permission boundaries. In practice, this makes the effective authority of the skill ambiguous and increases the risk that an agent or user will invoke it with broader access than intended.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The skill describes screenshot, DOM extraction, navigation, and script execution, but does not warn that these operations can access sensitive page contents such as tokens, personal data, or authenticated account information. In a browser-automation context, absence of privacy guidance materially increases the chance of accidental collection or exposure of sensitive data.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

Automated navigation, clicking, typing, and script execution can perform real actions on websites, including submissions, purchases, account changes, or destructive operations, yet the documentation does not warn about these consequences. In this context, the skill controls a real browser rather than a simulator, so unintended actions can have immediate external effects.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

All natural-language comments and console messages are in Chinese, including the instruction telling the user to respond with 已登录. This imposes a specific language on users without documenting a locale restriction or providing an opt-in/alternative, which matches the stated language/locale policy violation category.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The manifest describes a generic browser automation skill that supports navigation, clicking, input, screenshots, and DOM retrieval via WebSocket control. This file instead hard-codes navigation to a specific third-party site (fanqie.baidu.com/writer) and is oriented toward checking login/publishing workflow state, which is narrower and different from the claimed general-purpose browser controller.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The file's human-facing comments and runtime messages are written in Chinese, and there is no indication that language selection is configurable or that the skill is intentionally region-specific. Under the stated policy, forcing a specific language without user opt-in is a locale-policy concern.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

Launching Chromium with '--remote-debugging-port=9222' opens an additional browser control interface outside the documented WebSocket API. If that port is reachable by other local or network actors, they may bypass application logic entirely and gain full browser inspection/control, including page contents, cookies, and automation commands.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The snapshot action collects and returns current values from input and textarea elements, which can expose typed secrets such as usernames, personal data, search queries, or even passwords if pages misuse input types. Because this happens remotely over the WebSocket API without notice or consent, a client can silently harvest sensitive form data from any loaded page.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The description and changelog force a single language presentation, and the rest of the skill documentation continues in Chinese with no opt-in or note that the skill is intended only for Chinese-speaking users. Under the language/locale policy, a fixed language without user choice or explicit justification is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

The manifest description is written only in Chinese ("AI 可控的 WebSocket 浏览器,基于 Puppeteer"), which can indicate a language-specific skill presentation without any stated user opt-in or documented locale constraint. Under the policy rule, language-specific behavior or presentation should either offer user choice or clearly justify the locale restriction.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
87% confidence
Finding

Using a caret range for puppeteer allows future installs to resolve to different versions than were originally tested, which weakens build reproducibility and can silently introduce vulnerable or breaking releases. In a browser-automation skill that controls a real Chromium instance, dependency drift is more sensitive because security posture depends heavily on the exact browser automation stack shipped.

Content

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

json
"install-deps": "npm install puppeteer ws"
  },
  "dependencies": {
    "puppeteer": "^21.0.0",
    "ws": "^8.14.0"
  }
}

Unverifiable Dependency: puppeteer has 1 known advisory(ies) (CVE-2019-5786 (Use-After-Free in puppeteer)), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
40% confidence
Finding

Dependency has known vulnerabilities (CVEs). Using packages with unpatched security flaws exposes the environment to known exploits.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
93% confidence
Finding

Using a caret range for ws permits automatic resolution to newer minor/patch releases at install time, reducing reproducibility and making it unclear which security fixes or regressions are actually deployed. Because this skill exposes browser control over WebSocket, weaknesses in the WebSocket library have direct relevance to the attack surface and could amplify denial-of-service or memory disclosure risks if an affected version is installed.

Content

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

json
},
  "dependencies": {
    "puppeteer": "^21.0.0",
    "ws": "^8.14.0"
  }
}

Unverifiable Dependency: ws has 7 known advisory(ies) (CVE-2016-10518 (Remote Memory Disclosure in ws); CVE-2024-37890 (ws affected by a DoS when handling a request with many HTTP headers); CVE-2026-45736 (ws: Uninitialized memory disclosure) +4 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
89% confidence
Finding

The manifest does not pin ws, and the package has a substantial advisory history including denial-of-service and memory disclosure classes of issues. Given this skill's core design relies on WebSocket-based remote browser control, uncertainty about the exact ws version materially increases risk because a vulnerable resolution would sit directly on the exposed communication path.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
81% confidence
Finding

The manifest emphasizes WebSocket real-time browser control and automatic reconnection as distinguishing features. In this file, the code attaches to an already running Chrome instance via browserURL: 'http://127.0.0.1:9222', with no explicit WebSocket handling or reconnection logic present, so the documented behavior is only partially reflected here.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The script silently writes a screenshot of a logged-in browser session to a local file, which may capture sensitive account data, drafts, cookies-linked session state visible on screen, or other private content. In a browser automation skill, undisclosed artifact creation increases privacy and data-handling risk, especially when targeting an authenticated creator backend.

Content

No source excerpt is available for this finding.