Back to skill

Security audit

Asf V4

Security checks for vulnerabilities and agentic risk

Overview

The skill appears to be a broad development and governance toolkit rather than a focused parser, with several powerful or unsafe surfaces that need review before installation.

Review this as a broad governance/admin toolkit, not just a requirement parser. Install only if you trust the publisher and can constrain command execution, deployment, outbound network access, file-write locations, and memory/log visibility. Ask the publisher for consistent provenance, signed or pinned release evidence, and clearer confirmation/dry-run behavior for deployment and CLI commands.

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 (4)

T09 · Insecure Skill Coding Practices

Error
Location
tools/style-diagnostic.ts:105
Finding

Unrestricted URL Probing Enables Server-Side Request Forgery

Content
View full analysis
{ console.log('🔍 Probing style resources...\n'); const defaultUrls = [ 'https://cdn.example.com/styles/main.css', 'https://cdn.example.com/styles/critical.css', 'https://fonts.googleapis.com/css2?family=Inter', ]; const urlsToProbe = urls || defaultUrls; const results: { url: string; status: string; ok: boolean }[] = []; for (const url of urlsToProbe) { try { const controller = new AbortController(); const timeoutId = setTimeout(() => controller.abort(), 5000); const response = await fetch(url, { method: 'HEAD', signal: controller.signal, }); clearTimeout(timeoutId); results.push({ url, status: `${response.status} ${response.statusText}`, ok: response.ok, }); } catch (error) { results.push({ url, status: `Error: ${error}`, ok: false, }); } } ``` ### Technical Analysis `cmdStyleProbe` performs server-side HTTP requests to every caller-supplied URL. It does not restrict URL schemes or destinations, resolve and validate host addresses, block private and link-local networks, or validate redirect destinations. The method returns HTTP status information, providing an attacker with a network-reachability oracle. The five-second timeout limits request duration but does not prevent SSRF. The function is exported, and `runStyleDiagnostic('probe', args)` passes its argument array directly to it. Exploitation therefore requires access to this exported diagnostic API or a command surface that exposes it. ### Attack Path 1. An attacker gains permission to invoke the style diagnostic function or a command mapped to `runStyleDiag ...[truncated 1056 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
tools/style-diagnostic.ts:356
Finding

Caller-Controlled Report Path Allows Arbitrary File Overwrite

Content
View full analysis
{ switch (command) { case 'status': return cmdStyleStatus(); case 'probe': return cmdStyleProbe(args); case 'kpi': return cmdStyleKPI(); case 'contract': return cmdStyleContract(); case 'report': const outputFile = args.find(arg => arg.startsWith('--output='))?.split('=')[1]; return cmdStyleReport(outputFile); ``` ### Technical Analysis The `--output` argument is parsed directly from caller-controlled input and passed to `writeFileSync`. The path is not canonicalized or restricted to a designated reports directory. The code also does not reject absolute paths, traversal sequences, or symbolic links. `writeFileSync` uses overwrite behavior by default. Consequently, any file writable by the Skill process can be replaced with the generated JSON report. The attacker cannot directly choose arbitrary file contents through this path; the written content is the generated report. Nevertheless, replacing a configuration, source, state, or data file with JSON can cause corruption, denial of service, or unsafe behavior in another component. ### Attack Path 1. An attacker gains permission to invoke `runStyleDiagnostic` with the `report` command. 2. The attacker supplies an argument such as `--output=/path/to/writable/target`. 3. `runStyleDiagnostic` extracts the path without validation. 4. `cmdStyleReport` runs its checks and calls `writeFileSync` on the supplied path. 5. The existing target is replaced with report JS ...[truncated 717 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
src/security-sandbox.ts:128
Finding

Sandbox Path Checks Can Be Bypassed Through Traversal and Prefix Confusion

Content
View full analysis
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
SKILL.md:62
Finding

Conflicting Package Provenance Weakens Installation Supply-Chain Assurance

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
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
Findings (132)

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 · src/comfyui/brand-style-transfer.ts (reported line 392)May include surrounding context.

ts
prompt += 'Add text annotations, arrows, and callouts. ';
    }

    return prompt;
  }

  /**

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 · src/comfyui/user-flow-visualizer.ts (reported line 236)May include surrounding context.

ts
prompt += 'Add text annotations, arrows, and callouts. ';
    }

    return prompt;
  }

  /**

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 · src/memory/embedding_options.ts (reported line 17)May include surrounding context.

ts
* 
 * 4. 如果出现 sharp 安装问题:
 *    - 方案 A: 安装系统依赖
 *      sudo apt-get update && sudo apt-get install -y build-essential
 *    - 方案 B: 跳过 sharp
 *      npm install --ignore-scripts
 */

Credential Access

High
Category
Privilege Escalation
Confidence
90% confidence
Finding

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

Content

Scanner excerpt · src/sandbox/__tests__/sandbox.test.ts (reported line 46)May include surrounding context.

ts
});

  test('should check file access - denied path', () => {
    const allowed = sandbox.checkFileAccess('/root/.ssh/id_rsa', 'read');
    expect(allowed).toBe(false);
    
    const status = sandbox.getStatus();

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 · src/sandbox/__tests__/sandbox.test.ts (reported line 55)May include surrounding context.

ts
});

  test('should check file access - read-only write', () => {
    const allowed = sandbox.checkFileAccess('/etc/passwd', 'write');
    expect(allowed).toBe(false);
    
    const status = sandbox.getStatus();

Intent-Code Divergence

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The code presents a 'SecuritySandbox' that appears to enforce isolation, but the core execution path only calls simulateCodeExecution(), which performs a few string checks and does not provide real process, filesystem, network, or syscall isolation. In a security-sensitive skill, this mismatch is dangerous because callers may trust the API as a containment boundary and execute untrusted code under false assumptions, leading to sandbox escape by design rather than by exploit.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The file bundles rollback, deployment, Git revert, backup, and notification capabilities into a requirement-refinement skill module, violating separation of duties and greatly expanding the blast radius if this skill is invoked or reused in an unsafe context. Even though the methods are mostly stubbed, they establish a control-plane pattern unrelated to parsing, and in an agent ecosystem this kind of over-privileged functionality can later be wired to real infrastructure and abused for unauthorized operational changes.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

This manifest file uses the regex pattern "设计\b" to map requests to the figma design system. The term means simply "design" and is broad enough to overlap with many ordinary user requests, making activation or routing ambiguous rather than narrowly scoped.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The alias list for the apple design system includes "水果" (fruit), which is a common everyday word unrelated to the design system. Using such a broad alias increases the chance of accidental invocation or misclassification during natural-language matching.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The status output advertises capabilities such as 'mcp-bus', 'sandbox-executor', 'agent-harness', 'canary-deployer', and related Layer 8.5 features as present and enabled. In this file, those capabilities are not actually implemented here; only a few commands dynamically import a governance control plane, so the status metadata materially overstates what the skill itself provides.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The CLI wrapper dynamically imports and runs a CLI command based on user-controlled arguments without any allowlist, warning, or confirmation step in this file. If the underlying CLI can perform filesystem, network, or administrative actions, this becomes a powerful execution surface that an agent could misuse through untrusted input or prompt injection.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The deployment command invokes a governance control plane to deploy policy changes directly from user-supplied input with no confirmation, dry-run, authorization check, or safety interlock visible in this file. In an agent context, that increases the risk of unintended or prompt-induced system-affecting changes being executed immediately.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The function persists governance change events containing potentially sensitive fields such as target.idOrPath, actorRoleId, ownership metadata, and project identifiers, and also logs parts of that data to the console. In this skill context, the data describes internal code/graph/contract resources and governance actions, so storing and exposing it without minimization, access controls, or redaction can leak internal topology and operational metadata to unauthorized users or logs.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The inline documentation at L058 says this check verifies there is no eval() usage, but the script itself uses eval in the check() helper at L031. This is an active contradiction between the script's stated security intent and its actual implementation, even if the helper is not used later in this file.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/update-providers-config.js (reported line 21)May include surrounding context.

js
// 添加 Anthropic Provider
config.models.providers.anthropic = {
  baseUrl: 'https://api.anthropic.com/v1',
  apiKey: '${ANTHROPIC_API_KEY}',
  api: 'anthropic-completions',
  models: [

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/update-providers-config.js (reported line 48)May include surrounding context.

js
// 添加 OpenAI Provider
config.models.providers.openai = {
  baseUrl: 'https://api.openai.com/v1',
  apiKey: '${OPENAI_API_KEY}',
  api: 'openai-completions',
  models: [

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/update-providers-config.js (reported line 75)May include surrounding context.

js
// 添加 DeepSeek Provider
config.models.providers.deepseek = {
  baseUrl: 'https://api.deepseek.com/v1',
  apiKey: '${DEEPSEEK_API_KEY}',
  api: 'openai-completions',
  models: [

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

This command explicitly advertises running arbitrary CLI subcommands ('synthesize|preview|verify|role|ui|skill|harness|mcp') and presents it as a generic command runner without any user-facing warning about subprocess or shell-like effects. In an agent-skill ecosystem, such a broad execution surface can normalize unsafe invocation and increase the risk of command abuse, privilege misuse, or execution of impactful operations through agent mediation.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
86% confidence
Finding

This manifest exposes an anfsf:deploy command for canary deployment, which is a system-affecting operation, but the description and usage provide no warning about modifying live environments, rollout risk, or the need for confirmation. In a manifest file, user-facing command descriptions are the place where users would expect disclosure of impactful behavior.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · skill.yaml (reported line 589)May include surrounding context.

yaml
- "样式加载优化 (V1.5.0)"
      - "assetManifest 强制纳入 Contract Pack"
      - "Readiness Gate 样式探针实时检测"
      - "Ownership Lattice ui:style/** autoApprove 规则"
      - "Harness 样式加载断言 testStyleLoading()"
      - "Critical CSS 内联校验"
      - "ProgressiveEvolutionFramework 样式 KPI (>99%)"

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

This TypeScript test file contains natural-language expectations in Chinese, such as requiring the reason text to contain '安全优先原则'. Because SQP-3 applies to all file types, hard-coding a specific language in validation behavior can violate language/locale policy when no opt-in or justification is provided.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
82% confidence
Finding

This file’s natural-language descriptions and comments present the skill in a single language only, which can violate a language/locale policy when no user opt-in or explicit regional justification is provided. The file does not indicate that Chinese is optional or that the skill is intended exclusively for a Chinese-speaking or region-specific environment.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The method is named and documented as validating brand compliance, but it uses Math.random() to fabricate compliance results instead of inspecting the video. This can cause downstream systems or users to trust false pass/fail decisions, leading to policy bypass, bad moderation outcomes, or release of non-compliant content under a misleading assurance boundary.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The natural-language documentation and inline descriptions in this file are exclusively in Chinese, which effectively forces a specific language for operators and maintainers. The file does not offer an opt-in language choice or explain that the skill is intentionally limited to a Chinese-language or region-specific context.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The file advertises automatic rollback as a governance safety control, but the rollback implementation only marks the session as rolled back, emits a notification, and clears the in-memory session. It does not actively restore routing/configuration state or revoke any already-enabled canary traffic, which can leave a bad version still receiving production traffic despite operators believing rollback succeeded.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.dynamic_code_execution

Dynamic code execution detected.

Critical
Code
suspicious.dynamic_code_execution
Location
scripts/security-audit.sh:58