Back to skill

Security audit

99999

Security checks for vulnerabilities and agentic risk

Overview

This skill is a straightforward guide for creating Claude Code skills, with persistent skill-file creation disclosed and aligned with its purpose.

Install this if you want help drafting Claude Code skills. Because any created skill can persist and influence future agent behavior, review generated SKILL.md files and any optional scripts/templates before placing them in a personal or project skills directory.

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
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (9)

Self-Modification

High
Category
Rogue Agent
Confidence
85% confidence
Finding

This skill explicitly guides the agent to create or modify SKILL.md files, which is a form of self-modification in the agent ecosystem. Even though the intent is benign, allowing an agent to author or alter skills can introduce persistence, privilege broadening, or future instruction injection if used without strong user confirmation and scope controls.

Content

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

└── template.txt (optional)

text

### Step 4: Write SKILL.md frontmatter

Create YAML frontmatter with required fields:

Session Persistence

Medium
Category
Rogue Agent
Confidence
74% confidence
Finding

The skill is designed to help create durable agent skills that persist beyond the current session, which introduces session persistence risk. In a trusted workflow this is useful, but if abused it could plant long-lived instructions or helper scripts that alter future agent behavior without repeated user intent.

Content

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

md
# Skill Writer

This Skill helps you create well-structured Agent Skills for Claude Code that follow best practices and validation requirements.

## When to use this Skill

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
85% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

md
**Personal Skills** (`~/.claude/skills/`):
- Individual workflows and preferences
- Experimental Skills
- Personal productivity tools

**Project Skills** (`.claude/skills/`):
- Team workflows and conventions

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
85% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

bash
# Personal
mkdir -p ~/.claude/skills/skill-name

# Project
mkdir -p .claude/skills/skill-name

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
85% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

mkdir -p ~/.claude/skills/skill-name

Project

mkdir -p .claude/skills/skill-name

text

For multi-file Skills:

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
85% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

  1. Check file location:
    bash
    ls ~/.claude/skills/skill-name/SKILL.md
    ls .claude/skills/skill-name/SKILL.md
    

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
80% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

  1. Check file location:
    bash
    ls ~/.claude/skills/skill-name/SKILL.md
    ls .claude/skills/skill-name/SKILL.md
    

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
80% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

  1. Check file location:
    bash
    ls ~/.claude/skills/skill-name/SKILL.md
    ls .claude/skills/skill-name/SKILL.md
    

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
85% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

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

  1. Check file location:

    bash
    ls ~/.claude/skills/skill-name/SKILL.md
    ls .claude/skills/skill-name/SKILL.md
    
  2. Validate YAML:

Static analysis

No suspicious patterns detected.