Back to skill

Security audit

Skill Pilot

Security checks for vulnerabilities and agentic risk

Overview

SkillPilot appears to be a real scheduler, but it gives invoked tools broad inherited environment access and stores user request history in plaintext.

Install only if you are comfortable letting this skill execute other local skills and CLIs. Run it in a restricted environment with minimal environment variables, avoid placing secrets under the skill directory before packaging, and treat its history and reports as sensitive local data because queries, URLs, errors, and context may be retained in plaintext.

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
scripts/engine.py:352
Finding

Unrestricted Environment Variable Disclosure to Child Skills and External Tools

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/learning.py:37
Finding

Plaintext Persistence of Sensitive Queries, URLs, Errors, and Execution Context

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/package_skill.py:65
Finding

Skill Packaging Recursively Includes Potential Credentials and Runtime Telemetry

Content
View full analysis
bool: for pattern in exclude_patterns: if pattern in str(path) or path.name == pattern or path.match(pattern): return True return False # Package files with zipfile.ZipFile(zip_path, 'w', zipfile.ZIP_DEFLATED) as zipf: for file_path in skill_path.rglob('*'): if file_path.is_file() and not should_exclude(file_path): relative_path = file_path.relative_to(skill_path) zipf.write(file_path, relative_path) print(f" Added: {relative_path}") ``` ### Technical Analysis The packaging routine recursively archives every regular file that does not match a short exclusion set. The exclusions cover bytecode, Git metadata, logs, and the distribution directory, but they do not cover common sensitive artifacts such as: - `.env` and `.env.*` files. - Private keys and certificates. - Credential or token configuration files. - Generated execution history. - Environment caches and local state. - Diagnostic reports. - Editor and temporary backup files. - Local databases or credential stores. Because the archive is intended for publication or sharing, local-only data below the selected skill directory can cross a security boundary without the user realizing it. The included file list is printed, but there is no approval gate, secret scan, or safe default manifest. ### Attack Path 1. A developer runs SkillPilot locally and generated caches, history, reports, or configuration accumulate below the skill directory. 2. The developer also stores a credential file, private key, `.env` file, or local configuration in ...[truncated 969 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Note
Location
scripts/test.py:28
Finding

Shell Command Injection Through an Unquoted Project Path in the Test Utility

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (94)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_DECLARATION.md (reported line 154)May include surrounding context.

python3 run_search.py "今日热点" # ✅ 正常执行

注入尝试

python3 run_search.py "test; rm -rf /" # ❌ 拒绝执行 python3 run_search.py "test | cat /etc/passwd" # ❌ 拒绝执行 python3 run_search.py 'test $(whoami)' # ❌ 拒绝执行

text

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
60% confidence
Finding

Code enumerates, copies, or searches environment variables for secrets. Bulk environment access can collect credentials unrelated to the skill's stated purpose.

Content

Scanner excerpt · SECURITY_DECLARATION.md (reported line 205)May include surrounding context.

3. 环境变量传递 (scripts/engine.py)

python
# 检查点:subprocess.run 的 env 参数
env = os.environ.copy()  # 继承环境变量
result = subprocess.run(cmd, env=env, ...)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
80% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 17)May include surrounding context.

python
# ❌ 漏洞代码
cmd = f'''bash "skills/multi-search-engine/scripts/search.sh" "{query}"'''
subprocess.run(cmd, shell=True, ...)

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_DECLARATION.md (reported line 154)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 23)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 24)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 149)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
85% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_DECLARATION.md (reported line 154)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
85% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 23)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
85% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 24)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
85% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 149)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 23)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · SECURITY_FIX.md (reported line 23)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · SECURITY_DECLARATION.md (reported line 154)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · SECURITY_FIX.md (reported line 23)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · SECURITY_FIX.md (reported line 24)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · SECURITY_FIX.md (reported line 149)May include surrounding context.

风险: 用户输入的 query 直接嵌入 shell 命令,攻击者可注入恶意命令

bash
# 攻击示例
query = "test; rm -rf /"
# 执行:bash "skills/.../search.sh" "test; rm -rf /"

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · SECURITY_DECLARATION.md (reported line 155)May include surrounding context.

md
# 预期:拒绝执行,返回错误

# 3. 注入尝试 - 管道
python3 run_search.py "test | cat /etc/passwd"
# 预期:拒绝执行,返回错误

# 4. 注入尝试 - 命令替换

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · SECURITY_FIX.md (reported line 153)May include surrounding context.

md
# 预期:拒绝执行,返回错误

# 3. 注入尝试 - 管道
python3 run_search.py "test | cat /etc/passwd"
# 预期:拒绝执行,返回错误

# 4. 注入尝试 - 命令替换

Tp4

High
Category
MCP Tool Poisoning
Confidence
91% confidence
Finding

This finding includes an undeclared filesystem write location for reports under the workspace, which is a real capability expansion if not clearly surfaced in permissions or behavior docs. Hidden or insufficiently declared writes can overwrite user data, persist sensitive outputs, or create an unexpected foothold for later processing, especially in an orchestration skill that handles broad inputs.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
90% confidence
Finding

This finding includes an undeclared filesystem write location for reports under the workspace, which is a real capability expansion if not clearly surfaced in permissions or behavior docs. Hidden or insufficiently declared writes can overwrite user data, persist sensitive outputs, or create an unexpected foothold for later processing, especially in an orchestration skill that handles broad inputs.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

This finding includes an undeclared filesystem write location for reports under the workspace, which is a real capability expansion if not clearly surfaced in permissions or behavior docs. Hidden or insufficiently declared writes can overwrite user data, persist sensitive outputs, or create an unexpected foothold for later processing, especially in an orchestration skill that handles broad inputs.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
91% confidence
Finding

This finding includes an undeclared filesystem write location for reports under the workspace, which is a real capability expansion if not clearly surfaced in permissions or behavior docs. Hidden or insufficiently declared writes can overwrite user data, persist sensitive outputs, or create an unexpected foothold for later processing, especially in an orchestration skill that handles broad inputs.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
92% confidence
Finding

This finding includes an undeclared filesystem write location for reports under the workspace, which is a real capability expansion if not clearly surfaced in permissions or behavior docs. Hidden or insufficiently declared writes can overwrite user data, persist sensitive outputs, or create an unexpected foothold for later processing, especially in an orchestration skill that handles broad inputs.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

This finding includes an undeclared filesystem write location for reports under the workspace, which is a real capability expansion if not clearly surfaced in permissions or behavior docs. Hidden or insufficiently declared writes can overwrite user data, persist sensitive outputs, or create an unexpected foothold for later processing, especially in an orchestration skill that handles broad inputs.

Content

No source excerpt is available for this finding.