Back to skill

Security audit

zhanfu-playwright

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent ZhanFu automation helper, but it handles high-value account credentials and store-management actions through weakly scoped local mechanisms that users should review carefully before installing.

Install only if you trust the local machine and the ZhanFu workflow. Avoid entering owner or store passwords on shared or monitored systems, verify the real ZhanFu client is listening before login, and require explicit confirmation before cache clearing, account changes, plugin changes, or client termination.

Vulnerability Patterns
  • Tool Hijacking and SpoofingModifies or replaces tools so legitimate-looking calls execute attacker logic
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (5)

T07 · Tool Hijacking and Spoofing

Error
Location
scripts/zhanfu_http.py:164
Finding

Spoofable Plaintext Loopback API Can Capture Sensitive Credentials

Content
View full analysis
dict[str, Any]: if is_mac() and action in MAC_UNSUPPORTED: raise RuntimeError(f"macOS 暂不支持 {action}") api_port = preferred_port() if port is None else int(port) bid = "" if browser_id in (None, "") else str(browser_id) payload = { "module": "WebDriverModule", "action": action, "browserId": bid, "args": args, } resp = requests.post( f"http://127.0.0.1:{api_port}", json=payload, headers={"Content-Type": "application/json"}, timeout=timeout, ) if not resp.text: raise RuntimeError(f"{action} 空响应 HTTP {resp.status_code}") return json.loads(resp.text) ``` Credentials are placed directly in this request: ```python data = call( "Login", args=json.dumps( {"username": ns.username, "password": ns.password, "isboss": True}, ensure_ascii=False, ), timeout=15, port=port, ) ``` The launcher attempts to identify the local service using only attacker-controlled response fields: ```python is_wd = data.get("module") == "WebDriverModule" or ( data.get("action") and ("returnObj" in data or "ret" in data) ) if not is_wd: return "foreign", None ``` ### Technical Analysis The Skill sends ZhanFu owner credentials, store credentials, and privileged store-management commands through unauthenticated HTTP on a loopback TCP port. Restricting the destination to `127.0.0.1` prevents direct remote interception, but does not authenticat ...[truncated 2092 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/login_zhanfu.py:15
Finding

Passwords Are Exposed Through Command-Line Arguments

Content
View full analysis
`. 3. The command is captured in shell history, process telemetry, agent execution logs, or process metadata. 4. Another local user, monitoring product, log reader, or compromised process retrieves the command line. 5. The exposed credential is reused to access the ZhanFu owner ...[truncated 444 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/zhanfu_playwright.py:1017
Finding

Store Creation Silently Uses Predictable Default Credentials

Content
View full analysis
dict[str, Any]: return { "mall_name": ns.mall_name, "mall_account": ns.mall_account or "test_account", "mall_password": ns.mall_password or "test_password", "platform": ns.platform or "自定义平台", "platform_url": ns.platform_url or "https://www.baidu.com", "mall_address": ns.mall_address or "", "tags": ns.tags or "", "authorizationMember": ns.authorization_member or "", "ip_content": ip_content, "browser_kernel_version": ns.browser_kernel_version, "window_ua": "", "mac_ua": "", "android_ua": "", "remark": ns.remark or "Playwright 自动化创建", } ``` ### Technical Analysis When the legacy consolidated CLI creates a store without explicit `--mall-account` or `--mall-password` values, it substitutes the known strings `test_account` and `test_password`. These credentials are embedded in distributed source code and are therefore predictable to any attacker. This behavior contradicts the documented security rule that credentials must not be guessed and differs from `scripts/zhanfu_ops.py`, which uses empty values when optional credentials are omitted. The use of the Python `or` operator also prevents a caller from intentionally supplying an empty value because an empty string triggers the insecure fallback. ### Attack Path 1. An operator or agent invokes `scripts/zhanfu_playwright.py --create` without explicit store credentials. 2. `build_create_args()` inserts `test_account` and `test_password`. 3. The credentials are sent to the local `CreateBrowser` API and associated with the new store configuration. 4. An attacker who knows the public source attempts the predictable values against th ...[truncated 603 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/zhanfu_ops.py:162
Finding

Irreversible Cache Deletion Does Not Enforce User Confirmation

Content
View full analysis
int: if ns.all: blocked = _need_win("ClearCacheFolder") if blocked is not None: return blocked from zhanfu_http import clear_opening_malls port = preferred_port() data = call("ClearCacheFolder", args="{}", timeout=30, port=port) ro = data.get("returnObj") or {} if not isinstance(ro, dict) or ro.get("success") is not True: msg = ro.get("msg") if isinstance(ro, dict) else data print(str(msg)) return emit({"ok": False, "status": "failed", "msg": str(msg)}, 1) clear_opening_malls() print("已清除全部店铺缓存。") return emit({"ok": True, "status": "cleared_all"}, 0) blocked = _need_win("ClearCache") if blocked is not None: return blocked if not ns.mall_name: print("单店清缓存需要 --mall-name,或使用 --all") return emit({"ok": False, "status": "missing_args"}, 1) port = preferred_port() mall_id = resolve_mall_id(ns.mall_name, port=port) data = call("ClearCache", browser_id=mall_id, args="", timeout=30, port=port) ``` The CLI parser exposes the operation without a confirmation control: ```python k = sub.add_parser("clear-cache") k.add_argument("--mall-name", default="") k.add_argument("--all", action="store_true") ``` ### Technical Analysis The documentation describes cache clearing as irreversible and states that confirmation should be obtained before execution. The executable does not enforce that policy. Supplying `clear-cache --all` immediately invokes `ClearCacheFolder`, while a store name immediately invokes `ClearCache`. Relying exclusively on an agent instruction for confirmation is weaker than enforcing confirmation a ...[truncated 1309 chars]
Remediation
View remediation
` for a single store. - `--confirm-all-caches` for global deletion. 2. Reject non-interactive cache deletion unless the confirmation value exactly matches the intended scope. 3. Display the affected store or account scope before accepting confirmation. 4. For all-store deletion, use a second-factor confirmation phrase or short-lived confirmation token generated after a preview step. 5. Separate preview and execution: - First command lists the affected scope. - Second command consumes a short-lived token and performs deletion. 6. Record a non-sensitive audit event identifying who requested the action, its scope, and its result. 7. Preserve the existing macOS block and ensure confirmation checks occur before any destructive API call. ]]>

T08 · Insecure Dependencies

Note
Location
scripts/requirements.txt:1
Finding

Third-Party Dependencies Are Open-Ended and Not Integrity-Pinned

Content
View full analysis
=1.40.0 requests>=2.28.0 ``` ### Technical Analysis Both dependencies use open-ended minimum-version constraints. A future installation can therefore resolve to versions that were not present during this audit. The dependency file also lacks cryptographic hashes and does not identify an approved package index. No malicious dependency was identified in the reviewed project. The risk arises because installation behavior is not reproducible and can change after review. If a future release or package-distribution channel is compromised, the Skill may install and execute unreviewed code. ### Attack Path 1. The Skill is installed or its dependencies are refreshed at a later date. 2. The package resolver selects the newest versions satisfying the `>=` constraints. 3. A selected release is compromised, malicious, or contains a newly introduced exploitable behavior. 4. Package code executes during installation or when imported by the Skill. 5. The compromised package inherits the Skill process's access to credentials, local files, browser contexts, and the ZhanFu API. ### Impact Assessment Dependency code runs with the same operating-system privileges as the Skill. A compromised dependency could potentially: - Read credentials supplied to the process. - Access the local ZhanFu API and Playwright browser contexts. - Read or modify files available to the executing user. - Send data to external systems. - Execute arbitrary code within the Skill process. This is a supply-chain hardening weakness rather than evidence that the current named packages are malicious. ]]>
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (73)

Tainted flow: 'payload' from os.environ.get (line 373, credential/environment) → requests.post (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/open_zhanfu.py (reported line 154)May include surrounding context.

python
"args": json.dumps({"page": 1, "limit": 20}),
    }
    try:
        resp = requests.post(
            url,
            json=payload,
            headers={"Content-Type": "application/json"},

Tainted flow: 'payload' from os.environ.get (line 373, credential/environment) → requests.post (network output)

Critical
Category
Data Flow
Confidence
91% confidence
Finding

The script accepts username and password via CLI arguments and transmits them over unauthenticated HTTP to a service on 127.0.0.1. While localhost reduces remote exposure, any local malicious process bound to the selected port could impersonate the expected service and capture credentials, especially because service verification is heuristic and the port can be reused.

Content

Scanner excerpt · scripts/open_zhanfu.py (reported line 379)May include surrounding context.

python
"args": json.dumps({"username": username, "password": password, "isboss": True}),
    }
    try:
        resp = requests.post(
            f"http://127.0.0.1:{port}",
            json=payload,
            headers={"Content-Type": "application/json"},

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The declared description presents a broad WebDriver/Playwright automation capability for 站斧/战斧 and mentions a workflow of obtaining a WebDriver port first, then using CDP for business execution. The supplied code does not do that. It assumes a port is already provided, connects over CDP, and only checks whether a security detection page indicates automation can proceed. This is related to the stated domain, but the primary purpose is materially narrower and different: security-status inspection, not general automation. No clearly malicious or unrelated behavior is present, but the description overstates and mischaracterizes what this code chunk actually does.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

There is a material description-behavior mismatch. The declared purpose describes a broader WebDriver/Playwright automation skill whose key architecture is: use HTTP only before obtaining the WebDriver port, then use CDP for business execution. The provided code instead is a narrow administrative utility for closing a store/browser instance in ZhanFu via HTTP calls. Its primary purpose is not Playwright automation, and it never transitions to CDP-based business logic. While it is related to the ZhanFu domain, the concrete behavior shown is substantially different from the declared workflow and capabilities.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The declared description presents a general-purpose ZhanFu WebDriver/Playwright automation capability and specifies a particular communication model: only HTTP before obtaining the WebDriver port, then CDP for business execution. The actual code chunk instead has a much narrower and different primary purpose: closing the ZhanFu client. It makes a single HTTP-style call to ExitClient, handles connection failure, clears some state, and emits an exit result. There is no evidence of WebDriver port discovery, Playwright/CDP automation, GUI enforcement, or business automation. This is a material description-behavior mismatch because the code's primary function is client termination, which is not represented by the declared purpose.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
88% confidence
Finding

The declared description presents a general WebDriver/Playwright automation capability centered on obtaining a WebDriver port and then using CDP for browser-driven business automation. The supplied code chunk does something materially different: it queries the ZhanFu service for a browser/shop list, handles login/availability errors, prints metadata, and saves the list to a cache file. There is no WebDriver-port discovery logic visible here, no CDP usage, and no Playwright/browser automation behavior. This is not just a supporting detail of the declared purpose; the primary behavior of this script is inventory/list retrieval and caching, which is undeclared in the description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
87% confidence
Finding

The declared description presents the skill as a WebDriver/Playwright automation module whose core behavior is to use HTTP only to obtain a WebDriver port and then execute business logic through CDP. The provided code instead performs a specific authentication task: it parses CLI credentials, invokes a Login API, handles communication/login failures, retrieves a browser list, and saves mall data to cache. This is materially narrower and different from the stated automation purpose, and it includes credentialed login and cache population capabilities not disclosed in the description. While both relate to 站斧, the actual code does not match the declared primary behavior.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The description emphasizes WebDriver/Playwright-based browser automation flow, specifically an HTTP phase only to obtain the WebDriver port followed by CDP-driven business execution. This code chunk does something materially different: it exposes administrative ZhanFu operations over HTTP for store/profile management and maintenance. While it is related to the same product ecosystem (站斧/战斧/ZhanFu), its primary purpose is not browser automation and it includes undeclared capabilities such as account modification, plugin management, download path configuration, and cache clearing. The macOS gating for some operations is partially consistent with platform-specific behavior, but the main described behavior (port acquisition and CDP/Playwright execution) is absent here, so this is a mismatch.

Content

No source excerpt is available for this finding.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 668)May include surrounding context.

md
路径:Skill 目录下 `[api_port.json](api_port.json)`(与 `SKILL.md` 同级)。

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 732)May include surrounding context.

md
路径:Skill 目录下 `[api_port.json](api_port.json)`(与 `SKILL.md` 同级)。

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 766)May include surrounding context.

md
路径:Skill 目录下 `[api_port.json](api_port.json)`(与 `SKILL.md` 同级)。

os.system() or os exec-family call

High
Category
Dangerous Code Execution
Confidence
85% confidence
Finding

os.system() and os exec-family calls run shell commands with the process's full privileges, enabling arbitrary command execution.

Content

Scanner excerpt · scripts/zhanfu_playwright.py (reported line 313)May include surrounding context.

python
"""冷启动前关闭旧进程(API 已运行时勿调用)。杀完最多等 1s,进程没了立刻继续。"""
    if is_windows():
        print("[杀进程] 正在关闭 站斧.exe ...")
        os.system("taskkill /f /t /im 站斧.exe 2>nul")
        deadline = time.monotonic() + KILL_WAIT_MAX_SEC
        while time.monotonic() < deadline:
            # tasklist 退出码 0 且含 站斧.exe 才算仍在跑

os.system() or os exec-family call

High
Category
Dangerous Code Execution
Confidence
85% confidence
Finding

os.system() and os exec-family calls run shell commands with the process's full privileges, enabling arbitrary command execution.

Content

Scanner excerpt · scripts/zhanfu_playwright.py (reported line 317)May include surrounding context.

python
deadline = time.monotonic() + KILL_WAIT_MAX_SEC
        while time.monotonic() < deadline:
            # tasklist 退出码 0 且含 站斧.exe 才算仍在跑
            rc = os.system('tasklist /FI "IMAGENAME eq 站斧.exe" 2>nul | find /I "站斧.exe" >nul')
            if rc != 0:
                break
            time.sleep(0.2)

os.system() or os exec-family call

High
Category
Dangerous Code Execution
Confidence
85% confidence
Finding

os.system() and os exec-family calls run shell commands with the process's full privileges, enabling arbitrary command execution.

Content

Scanner excerpt · scripts/zhanfu_playwright.py (reported line 323)May include surrounding context.

python
time.sleep(0.2)
    elif is_mac():
        print("[杀进程] 正在关闭 站斧 (killall) ...")
        os.system("killall 站斧 2>/dev/null")
        time.sleep(min(KILL_WAIT_MAX_SEC, 1.0))
    print(f"[杀进程] 完成(最多等 {KILL_WAIT_MAX_SEC}s,已退出则立即可启动)")

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill describes and authorizes powerful capabilities including shell execution, file reads/writes, local HTTP requests, credential handling, and browser/client control, but it does not declare an explicit tool scope such as permissions or allowed-tools. That creates unnecessary ambiguity around what the agent may execute and weakens containment for a high-impact automation skill.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill instructs users to provide sensitive account passwords and repeatedly discusses login flows, but it does not include clear guidance on minimizing exposure, redacting secrets from logs, or avoiding persistence. In an agent setting, this increases the risk of credential disclosure through conversation history, tool logs, scripts, or local files.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill allows creation and modification of persistent store credentials without an explicit warning that these are durable account changes and may affect future logins or operations. That can lead to accidental credential overwrites, loss of access, or unauthorized persistent changes if the request is misunderstood.

Content

No source excerpt is available for this finding.

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 627)May include surrounding context.

md
> **口误 / 同义**:客户说「**战斧**」=「**站斧**」。例如「打开战斧」「打开战斧打开 xxx」「关闭战斧」「重启战斧」分别按「打开站斧」「打开站斧打开 xxx」「关闭站斧」「重启站斧」执行。


| 客户意图                       | `GetBrowserList` 探测        | 动作                                                                                                                                                    |
| -------------------------- | -------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| **打开店铺**                   | **能取到数据**(站斧已打开)或有 HTTP 响应 | **禁止**杀进程 / 冷启动 / `ExitClient`;将 `mall_name` 写入 `opening_malls.json` → resolve mall_id → `GetBrowserWebDriver` **单次 5s** 判是否已开 → 未开/超时则 `OpenBrowser` |
| **关闭店铺**                   | **能取到数据**或有 HTTP 响应        | **禁止**杀进程 / 冷启动 / `ExitClient`;直接 HTTP:resolve mall_id → `CloseBrowser` → **从 `opening_malls.json` 去掉该店铺名**                                           |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 631)May include surrounding context.

md
| -------------------------- | -------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| **打开店铺**                   | **能取到数据**(站斧已打开)或有 HTTP 响应 | **禁止**杀进程 / 冷启动 / `ExitClient`;将 `mall_name` 写入 `opening_malls.json` → resolve mall_id → `GetBrowserWebDriver` **单次 5s** 判是否已开 → 未开/超时则 `OpenBrowser` |
| **关闭店铺**                   | **能取到数据**或有 HTTP 响应        | **禁止**杀进程 / 冷启动 / `ExitClient`;直接 HTTP:resolve mall_id → `CloseBrowser` → **从 `opening_malls.json` 去掉该店铺名**                                           |
| **关闭站斧** / **关闭战斧** / `ExitClient`    | 任意                         | `ExitClient` → **清空 `opening_malls.json`**                                                                                                            |
| **创建店铺**                   | **能取到数据**或有 HTTP 响应        | **禁止**重启;`CreateBrowser` → 等待同步 → resolve mall_id → `OpenBrowser`(参数见客户指南「七、创建店铺」)                                                                    |
| **修改店铺账号密码**               | **能取到数据**或有 HTTP 响应        | **禁止**重启;resolve mall_id → `UpdateAccount`(`browserId`=`mall_id`,`args.username`/`password` 由客户提供,可空;见「十二、修改店铺账号密码」)                              |
| **获取店铺列表**                 | **能取到数据**或有 HTTP 响应        | **禁止**重启;`GetBrowserList`(默认 `page=1, limit=10`,可按客户指定分页)→ 展示 `mall_list`;**同时将列表中 `mall_name` → `mall_id` 写入 `mall_cache.json`**                     |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 679)May include surrounding context.

text


| 字段            | 说明                                                                                          |
| ------------- | ------------------------------------------------------------------------------------------- |
| `api_port`    | 站斧 HTTP API 端口(首选默认 `12678`;冷启动时若占用则写入实际分配端口)                                                                  |
| `install_dir` | 站斧安装路径:Windows 为含 `站斧.exe` 的文件夹;macOS 为 `站斧.app` 路径(如 `/Applications/站斧.app`);**查找命中后立即写入** |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 683)May include surrounding context.

md
| ------------- | ------------------------------------------------------------------------------------------- |
| `api_port`    | 站斧 HTTP API 端口(首选默认 `12678`;冷启动时若占用则写入实际分配端口)                                                                  |
| `install_dir` | 站斧安装路径:Windows 为含 `站斧.exe` 的文件夹;macOS 为 `站斧.app` 路径(如 `/Applications/站斧.app`);**查找命中后立即写入** |
| `updated_at`  | 最近一次写入时间                                                                                    |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 687)May include surrounding context.

md
| 时机                                 | 动作                                                                                   |
| ---------------------------------- | ------------------------------------------------------------------------------------ |
| 每次任务开始                             | **先读** `api_port.json` 的 `api_port`;文件不存在则用 **12678**                                |
| 冷启动前查找站斧                           | **先读** `install_dir`:Windows 验证 `{install_dir}\站斧.exe`;macOS 验证 `.app` 存在;无效则走原始查找逻辑 |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 717)May include surrounding context.

md
> **禁止**再用 `CheckClientOpen` 的 `LoadSuccess` / `LoadFailed` 判断站斧是否已打开。「模块 undefined 未加载」等说明该端口上**已有 HTTP 服务**;若确认为站斧 WebDriver,用正确 JSON 的 `GetBrowserList` 重发即可;若是**非站斧**服务,走 `get_available_port` 换口冷启动,**不要**停占用方、**不要**要求客户释放端口。


| 场景                       | 动作                                                                                         |
| ------------------------ | ------------------------------------------------------------------------------------------ |
| 站斧已打开 + **打开店铺**         | **不重启**;写入 `opening_malls.json` → resolve mall_id → 已开确认 → 未开则 `OpenBrowser`               |
| 站斧已打开 + **关闭店铺**         | **不重启**;resolve mall_id → `CloseBrowser` → 清理 `opening_malls.json`                         |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 841)May include surrounding context.

md
| 情况                         | 动作                                                                                                                                   |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| 目标店铺**未打开**(含探测 **5s 超时**) | 直接 `OpenBrowser` → 等 10s → `GetBrowserWebDriver`                                                                                     |
| 目标店铺**已打开**                | **必须先询问客户**:「店铺 {mall_name} 已打开(WebDriverPort={port}),是否需要关闭店铺?」                                                                     |

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

Scanner excerpt · SKILL.md (reported line 843)May include surrounding context.

md
| 情况                         | 动作                                                                                                                                   |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| 目标店铺**未打开**(含探测 **5s 超时**) | 直接 `OpenBrowser` → 等 10s → `GetBrowserWebDriver`                                                                                     |
| 目标店铺**已打开**                | **必须先询问客户**:「店铺 {mall_name} 已打开(WebDriverPort={port}),是否需要关闭店铺?」                                                                     |
| 客户确认**需要关闭**               | `CloseBrowser` → 从 `opening_malls.json` 去掉该名 → 确认关闭成功后,再询问是否重新 `OpenBrowser`;确认后再写入配置并 `OpenBrowser` → 等 10s → `GetBrowserWebDriver` |
| 客户确认**不需要关闭** / 继续使用当前店铺   | **跳过** `OpenBrowser` 与 `CloseBrowser`,直接用现有 `WebDriverPort` 进入阶段 B 或结束                                                               |

Static analysis

No suspicious patterns detected.