Back to skill

Security audit

Sop Refiner

Security checks for vulnerabilities and agentic risk

Overview

This is a local SOP drafting helper that is low risk in its current configuration, though its script includes unused broader audit routines users should be aware of.

Install this if you want a Chinese-language assistant for turning existing SOP material into a conservative review draft. Keep inputs local and consider redacting sensitive operational or personal data; also note that the bundled script contains inactive audit modes that should not be enabled unless you intentionally want local file-audit behavior.

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
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • 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 (12)

Tp4

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

声明描述聚焦于 SOP 内容优化与流程改进建议,但代码实际并未实现面向 SOP 的专门“删冗余、补异常路径、补回滚、补质量门槛”逻辑。相反,它从 spec.json 读取模式,充当一个通用本地分析/审计工具:可扫描目录、抽取 Markdown 标题、统计 CSV 字段、匹配危险 shell/secret/private URL 模式,并检查 Skill 文件完整性与 frontmatter。虽然其中某些输出可能被用于流程改进场景,但其主要能力和用途明显更广,且包含与 SOP 优化无直接对应的代码库/文件审计功能。因此描述未准确代表实际行为,属于实质性不匹配。

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The skill includes a generic security-pattern scanner that searches arbitrary files or directories for secrets, dangerous shell snippets, and private URLs. That functionality materially exceeds the stated SOP-refinement purpose and enables repository/security auditing behavior on user-supplied paths, increasing the risk of unintended data inspection and scope creep.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill implements package/repository auditing logic that validates expected files and parses SKILL.md frontmatter, which is unrelated to refining SOP content. In context, this broadens the tool into a general skill/repo inspector and can expose internal project structure or metadata from arbitrary directories without being necessary for its advertised use.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The trigger examples are broad natural-language phrases such as '优化这份 SOP 让新人更容易执行' and '把异常路径补齐', which can overlap with ordinary workflow requests and cause the skill to activate unintentionally. While the skill itself is scoped to conservative SOP refinement and explicitly says it should not change approval boundaries, accidental invocation could still route sensitive governance or process-change requests into this skill when a more restrictive review path is needed.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
95% confidence
Finding

The skill advertises executable capabilities via python3 and references local input/output files, but it does not declare an explicit tool/permission scope such as allowed shell or file access. This creates an authorization ambiguity: an orchestrator or reviewer cannot easily constrain what the skill is permitted to read, write, or execute, increasing the risk of unintended file access or shell execution if the skill is invoked in a permissive environment.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The title, category label, summary, input hint, and section labels are all specified only in Chinese, indicating a fixed language/locale experience. There is no indication in this manifest that users can opt into another language or that the skill is intentionally limited to a Chinese-only context.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The directory-wide enumeration routine recursively walks arbitrary roots and collects multiple text/code file types, which is broader access than needed for refining a provided SOP. Even without exfiltration, this creates unnecessary visibility into repository contents and serves as an enabling primitive for the broader audit features in the script.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The generated report strings in make_structured_report are fixed Chinese text, which forces a specific language for user-facing output. The file does not provide any user opt-in, locale selection, or documented region-specific justification for this constraint.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

directory_report, csv_report, pattern_report, parse_frontmatter error messages, and skill_audit all emit fixed Chinese strings to the user. This is a natural-language policy issue because the script consistently enforces one language with no opt-in or alternative.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

This markdown file presents all user-facing guidance and audit conclusions in Chinese, but does not indicate that the skill is region-specific or that users can opt into another language. That can violate a language/locale policy when users are not given a choice.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

The template content and headings are entirely in Chinese, which implies a fixed output language for the skill. Under the policy, forcing a specific language without user opt-in is a natural-language policy concern unless the locale restriction is explicitly documented and justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

This markdown file presents all instructions and test criteria exclusively in Chinese, and it does not indicate that the user can choose another language or that the skill is intentionally limited to a Chinese-speaking context. Under the policy, forcing a specific language without user opt-in is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.