Back to skill

Security audit

Art Knowledge Helper Skill

Security checks for vulnerabilities and agentic risk

Overview

The skill is a legitimate art-book organizer, but its scripts can copy broad local document files into a Baidu-synced folder without enough confirmation or path safeguards.

Review this skill before installing. Only point config.json at a dedicated Downloads or staging folder that contains files you are comfortable copying, verify the knowledge-base and Baidu paths are distinct non-overlapping folders, and do not run archive_books.py or sync_to_baidu.py until you have manually reviewed the file list and cloud destination. Do not use the sharing guide for books unless you have the right to redistribute them.

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
scripts/archive_books.py:151
Finding

Unfiltered Documents Can Be Copied into a Cloud-Synchronized Directory

Content
View full analysis
str: """根据文件名关键词,判断书籍应归档到哪个分类""" name_lower = filename.lower() for keywords, category in CLASSIFICATION_RULES: for kw in keywords: if kw.lower() in name_lower: return category return '10_参考资料' # 默认归入参考资料 def get_archive_destinations(filename: str) -> tuple: """获取归档目标路径(本地 + 百度盘)""" category = classify_book(filename) return KB / category, (BD / category) if BD.exists() else None def archive_file(src_path: Path, dry_run: bool = False) -> dict: """归档单个文件,返回结果信息""" local_dest, bd_dest = get_archive_destinations(src_path.name) local_dest.mkdir(parents=True, exist_ok=True) dest_path = local_dest / src_path.name if dest_path.exists(): return {'status': 'exists', 'dest': str(dest_path), 'name': src_path.name} if dry_run: return {'status': 'would_copy', 'dest': str(dest_path), 'name': src_path.name} shutil.copy2(src_path, dest_path) # 同时复制到百度盘 if bd_dest: bd_dest.mkdir(parents=True, exist_ok=True) shutil.copy2(src_path, bd_dest / src_path.name) return {'status': 'archived', 'dest': str(dest_path), 'name': src_path.name} ``` ```python EXTENSIONS = {'.pdf', '.epub', '.mobi', '.azw3', '.djvu', '.cbz', '.cbr'} candidates = [ f for f in DOWNLOADS.iterdir() if f.is_file() and f.suffix.lower() in EXTENSIONS ] if not candidates: print("下载目录中没有找到书籍文件。") return print(f"📋 找到 {len(candidates)} 个候选文件,开始归档……") print() results = {'archived': [], 'skipped': [], 'errors': []} for f in candidates: try: result = archive_file(f) ``` ### Technical Analysis The archival script processes every top-level file in the configured Downloads directory whose ...[truncated 2390 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/sync_to_baidu.py:27
Finding

Unsafe Path Validation Permits Unintended and Overlapping Synchronization Roots

Content
View full analysis
None: """递归同步目录""" if not src_dir.exists(): print(f" ⚠️ 源目录不存在:{src_dir}") return dst_dir.mkdir(parents=True, exist_ok=True) for src_file in src_dir.rglob('*'): if not src_file.is_file() or should_skip(src_file): continue rel_path = src_file.relative_to(src_dir) dst_file = dst_dir / rel_path if dst_file.exists(): if dst_file.stat().st_size == src_file.stat().st_size: continue # 大小相同,跳过 else: dst_file.parent.mkdir(parents=True, exist_ok=True) try: shutil.copy2(src_file, dst_file) stats['copied'] += 1 stats['copied_mb'] += src_file.stat().st_size / 1024 / 1024 except Exception as e: stats['errors'].append(str(src_file)) print(f" ❌ 复制失败:{src_file.name}") ``` ### Technical Analysis The scripts construct `Path` objects before testing whether the underlying configuration strings are empty. In Python, `Path('')` represents the current directory and is truthy. Therefore, checks such as `if not KB` and `if not BD` do not reject an empty configuration value. The synchronization implementation also does not resolve paths to ca ...[truncated 2431 chars]
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
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (15)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The tutorial instructs users to run scripts that automatically scan downloads, classify files, copy them into a knowledge base, and synchronize them to Baidu Netdisk without clearly warning about file movement/copy side effects, metadata exposure, or cloud privacy implications. In a skill that operates on a user's personal Downloads folder and performs backup/sync, missing safety disclosures can lead to unintended processing of sensitive files and unreviewed propagation to cloud storage.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The README instructs users to run archival and Baidu sync scripts that can copy and reconcile large sets of files, but it does not warn about overwrite behavior, misclassification, duplicate creation, or accidental propagation of mistakes to the cloud. In a file-management skill, missing safety guidance increases the chance of user data loss or integrity issues because users may assume the operations are safe and reversible.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The guide instructs users to share a large repository of 333 books through Baidu cloud links without any discussion of copyright ownership, licensing, consent, or access-control risks. In the context of a knowledge-base skill managing a personal book archive, this creates a realistic risk of unauthorized distribution of copyrighted materials and oversharing of personal data or filesystem structure.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
88% confidence
Finding

The skill clearly describes scripts that read from downloads folders and write or synchronize files in a knowledge base, yet it declares no explicit tool scope or permission boundaries. In an agent setting, this increases the chance of over-broad file access or unintended file modification because operators cannot easily tell what filesystem capabilities the skill expects or limit them safely.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill advertises archiving, cleanup, and bidirectional sync operations but does not warn that these actions can overwrite, move, or delete user files. This is dangerous because users or an agent may run destructive maintenance tasks without understanding rollback needs, conflict handling, or the risk of propagating mistakes across both local and cloud-synced copies.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The skill explicitly encourages proactive scanning of a download directory and prompting about new book archival, but it does not disclose file-system access expectations, scope, consent, or trigger conditions. In a knowledge-base management skill that handles local collections and cloud-sync workflows, this can normalize background inspection of user files and lead to privacy-invasive behavior beyond what the user intended.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The entire user-facing template and instructions are written in Chinese, including labels and setup guidance, with no indication that other languages are supported or that Chinese is optional. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale constraint is clearly documented and justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This code file contains natural-language strings and documentation that force a specific language experience for users. Under the policy, language constraints should either be optional/opt-in or clearly justified as region-specific, neither of which is present here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
78% confidence
Finding

The file is entirely presented as a Chinese-only tutorial for end users, with no indication that language choice is optional or that the skill is intentionally limited to a Chinese-speaking or region-specific audience. Under the stated policy, forcing a specific language without user opt-in can be a natural-language policy violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
85% confidence
Finding

根据文件内容,技能说明、步骤和问答均仅以中文呈现,未见提供多语言选项、用户语言偏好选择,或说明该技能仅面向特定中文用户群体。按规则,未获用户选择即强制单一语言可构成语言/地区政策问题。

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
75% confidence
Finding

All user-facing natural-language description in this skill file is in Chinese, and there is no indication that the user may choose another language or that the locale restriction is intentional and justified. Under the policy, forcing a specific language without user opt-in can be a natural-language policy issue.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
74% confidence
Finding

The entire skill file is authored in Chinese and presents the assistant persona and behavior only in that language, with no indication that users may choose another language. Under the policy, forcing a specific language without user opt-in can be a natural-language policy violation unless the locale restriction is explicitly justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

The module docstring presents the tool name, usage, and instructions entirely in Chinese, which constitutes a natural-language locale constraint visible to users. There is no indication that Chinese is optional or that the skill is intentionally limited to a Chinese-speaking environment.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

This code file contains only Chinese natural-language documentation and user-facing text, including the header and usage instructions. Under the language/locale policy rule, forcing a specific language without user opt-in can be a policy violation when no alternative language choice is offered.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
96% confidence
Finding

The file-level docstring and all user-facing messages are written exclusively in Chinese, which imposes a specific language on users without any opt-in or alternative locale support. Under the policy criteria, this is a natural-language locale constraint that is not justified as region-specific in the file.

Content

No source excerpt is available for this finding.