Back to skill

Security audit

B站UP主数据采集

Security checks for vulnerabilities and agentic risk

Overview

This Bilibili data skill is mostly a read-only MaxHub wrapper, but it needs Review because it can request a full Bilibili session cookie for VIP playback and contains automatic fallback paths to non-Bilibili APIs.

Install only if you are comfortable sending requests and credentials to MaxHub at www.aconfig.cn. Avoid using the VIP playback feature with your main Bilibili browser cookie; use a disposable/test account or rotate the session afterward. Review the non-Bilibili fallback paths before relying on automatic degradation, and prefer a pinned, trusted installer version instead of an unversioned npx command.

Vulnerability Patterns
  • 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
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
Findings (2)

T09 · Insecure Skill Coding Practices

Error
Location
references/api-video.md:656
Finding

Full Bilibili Session Cookie Forwarded to a Third-Party Service

Content
View full analysis
⚠️ **Credential Handling** > - Some endpoints require platform session cookies. Only provide cookies if you fully trust the service provider. > - Prefer scoped OAuth/API tokens over full browser cookies. Use separate test accounts when possible. > - Rotate or revoke cookies after use. > 📋 **Data Transmission** > - All API requests are sent to `https://www.aconfig.cn`. Your credentials are transmitted to this third-party service. > - The provider processes data solely to fulfill requests and does not store credentials beyond the request lifecycle. ``` From `references/api-video.md:656-675`: ```markdown ## fetch_vip_video_playurl `POST /api/v1/bilibili/web/fetch_vip_video_playurl` ### Parameters No parameters required. ### Response Standard MaxHub response: `{code, message, message_zh, data, cache_url}` ### Description ### Purpose: - Retrieve VIP-quality video stream URLs ### Parameters: - bv_id: video identifier - cid: content identifier - cookie: VIP member user cookie ### Returns: - VIP-quality video stream URL ``` ### Technical Analysis The VIP playback endpoint requires the user's Bilibili session cookie to be transmitted to `https://www.aconfig.cn`. A browser session cookie is generally a bearer credential and may provide significantly broader account authority than the read-only playback operation needs. Forwarding the complete cookie to a third party therefore violates least-privilege principles. The endpoint documentation is also internally inconsistent. Its formal parameter section states that no parameters are required, while its description requires `bv_id`, `cid`, and `cookie`. The endpoint is absent from ...[truncated 1990 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
README.md:15
Finding

Unpinned Package Execution Through npx Installation Command

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (47)

Hidden Instructions

High
Category
Prompt Injection
Confidence
88% confidence
Finding

This duplicate finding points to the same hidden-instruction mechanism that treats comment content as trusted control data. When agents are told to follow hidden path markers, attackers or careless maintainers can influence execution in ways users and reviewers do not see, which is especially risky in a skill already containing mismatched platform references.

Content

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

md
| 禁止行为 | 正确做法 |
|----------|----------|
| ❌ 自行拼接路径(如 `/api/v1/douyin/search/xxx`) | ✅ 使用 Action Table 或 `<!-- Full path: -->` 中的路径 |
| ❌ 猜测参数名(如把 `aweme_id` 写成 `video_id`) | ✅ 使用 Action Table 或 reference 文件中的参数名 |
| ❌ 假设 v1/v2/v3 参数兼容 | ✅ 降级时重新读取对应版本的参数文档 |
| ❌ 调用 `fetch_hot_search_list` 或 `app/v3/fetch_video_comments` | ✅ 使用替代端点(见废弃标注) |

Hidden Instructions

High
Category
Prompt Injection
Confidence
88% confidence
Finding

This duplicate finding points to the same hidden-instruction mechanism that treats comment content as trusted control data. When agents are told to follow hidden path markers, attackers or careless maintainers can influence execution in ways users and reviewers do not see, which is especially risky in a skill already containing mismatched platform references.

Content

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

md
| 禁止行为 | 正确做法 |
|----------|----------|
| ❌ 自行拼接路径(如 `/api/v1/douyin/search/xxx`) | ✅ 使用 Action Table 或 `<!-- Full path: -->` 中的路径 |
| ❌ 猜测参数名(如把 `aweme_id` 写成 `video_id`) | ✅ 使用 Action Table 或 reference 文件中的参数名 |
| ❌ 假设 v1/v2/v3 参数兼容 | ✅ 降级时重新读取对应版本的参数文档 |
| ❌ 调用 `fetch_hot_search_list` 或 `app/v3/fetch_video_comments` | ✅ 使用替代端点(见废弃标注) |

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

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

md
| "analyze" / "分析一下" | Switch to analyze mode |
| "compare with X" / "和X对比" | Add X as second query |

## Output Guidelines

1. **Language consistency** — ALL output matches user's detected language.
2. **Markdown links** — All URLs in `[text](url)` format.

Intent-Code Divergence

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The skill is presented as a Bilibili-only read-only assistant, but its fallback logic instructs switching to Douyin and even references Xiaohongshu paths. This creates a scope-confusion vulnerability: the agent may transmit user queries, identifiers, or credentials to unintended platform endpoints, violating user expectations and potentially causing unauthorized cross-platform data access or policy bypass.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The documented execution/degradation flow includes non-Bilibili API paths despite the skill’s stated purpose and safety claims. This mismatch can cause the agent to perform actions outside the declared trust boundary, making external transmission and unintended data handling more dangerous because the user believes they are using a single-platform Bilibili tool.

Content

No source excerpt is available for this finding.

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-live.md (reported line 11)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_all_live_areas`

<!-- Full path: /api/v1/bilibili/web/fetch_all_live_areas -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-search.md (reported line 11)May include surrounding context.

md
`GET /api/v1/bilibili/app/fetch_bangumi_tab`

<!-- Full path: /api/v1/bilibili/app/fetch_bangumi_tab -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-search.md (reported line 53)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_general_search`

<!-- Full path: /api/v1/bilibili/web/fetch_general_search -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-search.md (reported line 127)May include surrounding context.

md
`GET /api/v1/bilibili/app/fetch_popular_feed`

<!-- Full path: /api/v1/bilibili/app/fetch_popular_feed -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-user.md (reported line 11)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_collect_folders`

<!-- Full path: /api/v1/bilibili/web/fetch_collect_folders -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-user.md (reported line 61)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_user_dynamic`

<!-- Full path: /api/v1/bilibili/web/fetch_user_dynamic -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-user.md (reported line 113)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_user_profile`

<!-- Full path: /api/v1/bilibili/web/fetch_user_profile -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 11)May include surrounding context.

md
`GET /api/v1/bilibili/web/bv_to_aid`

<!-- Full path: /api/v1/bilibili/web/bv_to_aid -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 61)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_comment_reply`

<!-- Full path: /api/v1/bilibili/web/fetch_comment_reply -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 115)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_dynamic_detail_v2`

<!-- Full path: /api/v1/bilibili/web/fetch_dynamic_detail_v2 -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 169)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_live_room_detail`

<!-- Full path: /api/v1/bilibili/web/fetch_live_room_detail -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 219)May include surrounding context.

md
`GET /api/v1/bilibili/app/fetch_one_video`

<!-- Full path: /api/v1/bilibili/app/fetch_one_video -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 271)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_one_video_v2`

<!-- Full path: /api/v1/bilibili/web/fetch_one_video_v2 -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 323)May include surrounding context.

md
`GET /api/v1/bilibili/app/fetch_reply_detail`

<!-- Full path: /api/v1/bilibili/app/fetch_reply_detail -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 383)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_user_post_videos`

<!-- Full path: /api/v1/bilibili/web/fetch_user_post_videos -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 415)May include surrounding context.

md
`GET /api/v1/bilibili/app/fetch_user_videos`

<!-- Full path: /api/v1/bilibili/app/fetch_user_videos -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 477)May include surrounding context.

md
`GET /api/v1/bilibili/app/fetch_video_comments`

<!-- Full path: /api/v1/bilibili/web/fetch_video_comments -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 529)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_video_detail`

<!-- Full path: /api/v1/bilibili/web/fetch_video_detail -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 579)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_video_play_info`

<!-- Full path: /api/v1/bilibili/web/fetch_video_play_info -->

### Parameters

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · references/api-video.md (reported line 631)May include surrounding context.

md
`GET /api/v1/bilibili/web/fetch_video_subtitle`

<!-- Full path: /api/v1/bilibili/web/fetch_video_subtitle -->

### Parameters

Static analysis

No suspicious patterns detected.