Back to skill

Security audit

Hotspot Aggregator

Security checks for vulnerabilities and agentic risk

Overview

The skill largely does what it advertises, but it saves untrusted online trend content into a persistent local memory path without sanitization or clear retention controls.

Install only if you are comfortable with a Chinese-language trend-monitoring skill that writes reports and fetched data under /root/clawd/memory/hotspots. Enable USE_REAL_API only after accepting outbound requests to the listed platforms, including the third-party Douyin aggregator. Treat generated reports as untrusted web content, review or delete stored reports periodically, and consider narrowing triggers or adding confirmation before automated fetch/report runs.

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

T02 · Agent Memory Poisoning

Error
Location
scripts/fetch-hotspots.sh:174
Finding

Persistent prompt-injection path through untrusted remote titles

Content
View full analysis
/dev/null 2>&1; then jq '{platform: "douyin", date: "'$DATE'", time: "'$TIME'", source: "real", data: [.result[] | {rank: .index, title: .name, play_count: .hot, author: "热门创作者"}]} | .data |= .[:10]' "$output.tmp" > "$output" rm -f "$output.tmp" log_info "抖音热搜(真实数据)已保存" return fi fi log_warn "真实API获取失败,使用模拟数据" fi ``` The same data flow exists for the other remote sources: ```bash # scripts/fetch-hotspots.sh:50-56 if [[ "$USE_REAL_API" == "true" ]]; then local url="https://weibo.com/ajax/side/hotSearch" if fetch_url "$url" "$output.tmp"; then if jq -e '.ok' "$output.tmp" > /dev/null 2>&1; then jq '[.data.realtime[] | {rank: .rank, title: .word, heat: .realpos, tag: .icon_desc}] | {platform: "weibo", date: "'$DATE'", time: "'$TIME'", data: .}' "$output.tmp" > "$output" ``` ```bash # scripts/generate-report.sh:71-84 generate_douyin_section() { local latest_file=$(ls -t "$DATA_DIR"/douyin_${DATE}_*.json 2>/dev/null | head -1) if [[ -z "$latest_file" ]]; then echo "⚠️ 未找到抖音热搜数据" return fi echo "## 🎵 抖音热搜 TOP10" echo "" jq -r '.data[] | "\(.rank). \(.title) 🎬 \(.play_count | tostring)播放"' "$latest_file" | head -10 echo " ...[truncated 2906 chars]
Remediation
View remediation

T01 · Skill Instruction Hijacking

Warning
Location
scripts/generate-report.sh:163
Finding

Mandatory promotional content appended to generated reports

Content
View full analysis
> "$REPORT_FILE" << EOF --- *热点聚合监控 | 让热点触手可及 🔥* EOF log_info "报告已生成: $REPORT_FILE" # 输出报告路径 echo "" echo "📄 报告位置: $REPORT_FILE" echo "" echo "---" cat "$REPORT_FILE" ``` ### Technical Analysis The report generator unconditionally appends a fixed promotional slogan to every generated report. No configuration option, command-line switch, or user confirmation controls this behavior. Because the same report is subsequently printed, the fixed content is inserted into both persistent output and immediate command output. A caller requesting a neutral aggregation report cannot prevent the branding without modifying the script. This does not alter the Agent's safety rules or execute code. However, it changes user-facing output for a purpose separate from presenting the requested hotspot data and may propagate into downstream publications or Agent responses. ### Attack Path 1. A user or Agent invokes `scripts/generate-report.sh`. 2. The script generates the requested hotspot sections. 3. The script appends the fixed promotional slogan regardless of the caller's preferences. 4. The modified report is saved under `/root/clawd/memory/hotspots`. 5. The script prints the branded report, allowing the promotional content to propagate to downstream output. ### Impact Assessment No additional system privileges are obtained. The impact is limited to integrity and control of generated content: reports are modified with mandatory promotional text and may be redistributed without the caller intending to endorse or advertise the skill. The issue affects every generated report because the footer is unconditional. ]]>
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (19)

Tp4

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

The documented behavior omits an important side effect: writing reports to a fixed local path under /root/clawd/memory/hotspots. Undisclosed persistent storage and automation behavior can surprise users, create privacy/retention issues, and bypass operator expectations about where monitored data is being stored.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
93% confidence
Finding

The skill advertises and instructs shell-script execution but does not declare any tool scope or permissions boundaries. This makes the operational capability implicit, which can lead to unexpected command execution in environments that rely on manifest-declared permissions for review and containment.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The trigger list includes very broad everyday terms like '热点', '热搜', and '舆情', increasing the chance of accidental invocation in normal conversation. Unintended activation can cause unsolicited network access, data fetching, file writes, or report generation without clear user intent.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The description highlights monitoring, report generation, and keyword push behavior but does not warn that the skill stores data locally and can run automatically via scheduled tasks. Users may unknowingly enable ongoing monitoring or persistence, creating privacy, consent, and operational-risk issues.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

This manifest file defines the monitored trigger scope using a single keyword, "AI", which is extremely broad and lacks any constraints, exclusions, or examples to limit when the skill should activate. Such a generic term is likely to overlap with a large amount of ordinary content, increasing the risk of unintended or noisy invocation behavior.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The trigger list includes broad, common terms such as “热点”, “热搜”, and “舆情”, which are likely to appear in many normal user conversations unrelated to explicitly invoking this skill. That can cause unintended activation and execution of the skill’s monitoring/reporting workflows, increasing the chance of surprise network activity or unintended handling of user context.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The comments and user-facing output strings throughout the script are written in Chinese, including usage and runtime messages. This imposes a specific language on users without offering opt-in, fallback, or documentation that the skill is intentionally limited to a Chinese-speaking context.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
83% confidence
Finding

When USE_REAL_API=true, the script sends outbound requests to a third-party aggregator endpoint and writes returned content to local files without any trust boundary controls, allowlisting, or privacy review. In this skill context, external transmission is expected for hotspot collection, but use of an unofficial third-party API increases supply-chain, integrity, and data-governance risk if the endpoint is compromised, blocked, or serves malformed content.

Content

Scanner excerpt · scripts/fetch-hotspots.sh (reported line 181)May include surrounding context.

sh
if [[ "$USE_REAL_API" == "true" ]]; then
        # 使用第三方聚合API
        local url="https://api.oioweb.cn/api/toutiao/douyinHot"
        if fetch_url "$url" "$output.tmp"; then
            if jq -e '.result' "$output.tmp" > /dev/null 2>&1; then
                jq '{platform: "douyin", date: "'$DATE'", time: "'$TIME'", source: "real", data: [.result[] | {rank: .index, title: .name, play_count: .hot, author: "热门创作者"}]} | .data |= .[:10]' "$output.tmp" > "$output"

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This shell script presents its comments, status messages, section headers, and report content entirely in Chinese, including user-facing output such as warnings and the generated report text. The file provides no opt-in, fallback, or documented justification for enforcing a specific language, which is a natural-language locale policy violation under the stated rules.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

This shell script uses Chinese-only comments, usage text, and runtime messages, which imposes a specific language on users without any opt-in or indication that the skill is intended only for a Chinese-speaking context. The policy allows locale constraints only when they are explicitly offered as a choice or clearly justified as region-specific.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
82% confidence
Finding

The skill description is entirely in Chinese and presents the skill as operating in that language, but the file does not state that the skill is region-specific or provide any user opt-in for language or locale. Under the stated policy, language constraints should either be optional for the user or explicitly justified.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger list contains very generic terms such as '热点', '热搜', '热榜', and 'hotspot', which are likely to match ordinary user requests about trending topics rather than explicit invocation of this skill. In an agent environment, overly broad triggers can cause unintended activation, hijack unrelated conversations, and route user requests into this skill without clear user intent.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
83% confidence
Finding

The README presents the skill entirely in Chinese and describes its behavior and outputs in that language, with no indication that users may choose another language or locale. Under the language/locale policy, forcing a specific language without opt-in can be a natural-language policy concern unless clearly justified as region-specific.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
79% confidence
Finding

This markdown file documents adding and removing subscribed keywords and separately states that reports are saved to a filesystem path, but it does not clearly warn users that their subscription terms and matched results may be persisted locally. Because keyword subscriptions can reflect user interests or sensitive topics, a brief disclosure about local storage and retention would improve user awareness.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
76% confidence
Finding

The primary description and trigger phrases are entirely Chinese-language, but the file does not state that the skill is China-specific or offer an alternative language option. Under the policy, forcing a specific language without opt-in can be a natural-language policy issue unless the locale restriction is explicit and justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
72% confidence
Finding

The description text is written only in Chinese and the configured platforms are exclusively Chinese services, but the file does not indicate whether this locale restriction is intentional, user-selected, or justified as a region-specific tool. That can create a natural-language locale policy concern if users are not given a language or region choice.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
75% confidence
Finding

The user-facing description is entirely in Chinese (L04), and the category includes "chinese" (L26), which signals a language-specific experience. The file does not indicate that users can opt into this locale or that the restriction is a documented region-specific requirement.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

At L66 the script invokes fetch-hotspots.sh, which is a subprocess execution. Although there are internal comments and log messages, there is no explicit user-facing warning that running this checker may trigger another script to fetch data automatically, which is a behavior that can affect the system or network unexpectedly.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

This shell script presents its description and user-facing status messages in Chinese only, as seen in the header comments and throughout the script. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale restriction is explicitly documented and justified, which is not present here.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.