Agent skill

Account Validation

by PlamenTSV in PlamenTSV/plamen

Trigger Pattern Always required for Solana audits - Inject Into Breadth agents, depth agents

MITAuto-check passed

Install Account Validation

skills CLI
$ npx skills add PlamenTSV/plamen --skill account-validation -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install PlamenTSV/plamen account-validation --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/PlamenTSV/plamen.git skills-src && mkdir -p .claude/skills && cp -r skills-src/agents/skills/solana/account-validation .claude/skills/account-validation && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
account-validation
GitHub stars
303
Token cost
~1.7k tokens
SKILL.md length
663 words
Files
1
Skills in repo
87
Repo updated
First seen
Licence
MIT

At a glance

Trigger Pattern Always required for Solana audits - Inject Into Breadth agents, depth agents

  • Works in 8 steps: Account Type Inventory → Owner Check Audit → Discriminator Check → …
  • Pattern Always required for Solana audits - Inject Into Breadth agents
  • SKILL.md covers 1. Account Type Inventory, 2. Owner Check Audit, 3. Discriminator Check and 4. Data Matching…, plus 6 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Account Validation is an agent skill from PlamenTSV/plamen. Trigger Pattern Always required for Solana audits - Inject Into Breadth agents, depth agents

Its SKILL.md is about 1.7k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It works with Solana. The repository describes itself as: Autonomous Web3 security audit agent for Claude Code. The licence is MIT.

When your agent uses it

  • Pattern Always required for Solana audits - Inject Into Breadth agents

Example prompts

  • “/account-validation”

Workflow steps

8 steps, taken from the step headings in SKILL.md.

  1. Account Type Inventory
  2. Owner Check Audit
  3. Discriminator Check
  4. Data Matching (Cross-Account References)
  5. Remaining Accounts Audit
  6. Duplicate Account Detection
  7. Sysvar Validation
  8. Trust Chain Analysis

What it can do on your machine

Read from SKILL.md and the folder at commit 795962b. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are markdown).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Account Validation loads about 1.7k tokens when it runs. Until then it costs about 28 tokens; SKILL.md has 663 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~28
When it runs · the whole SKILL.md, loaded when a task matches
~1.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from PlamenTSV/plamen at commit 795962b, republished under its MIT licence (© PlamenTSV). 663 words, ~1,727 tokens.

Download SKILL.mdSave it as .claude/skills/account-validation/SKILL.md (or your agent's skills folder).
name
account-validation
description
Trigger Pattern Always required for Solana audits - Inject Into Breadth agents, depth agents

ACCOUNT_VALIDATION Skill

Trigger Pattern: Always required for Solana audits Inject Into: Breadth agents, depth agents Finding prefix: [AV-N] Rules referenced: S1, S6, S7, S8, R4

For every instruction handler in the Solana program:

1. Account Type Inventory

For EACH instruction, list every account with expected constraints:

#Account NameExpected OwnerExpected Type (Discriminator)Mutable?Signer?Constraints (has_one, seeds, etc.)
1{name}{program_id / system / token}{Account<T> / UncheckedAccount / etc.}YES/NOYES/NO{list all}

Anchor auto-checks: Anchor's Account<T> validates owner + discriminator automatically. UncheckedAccount / AccountInfo do NOT - manual validation required.

2. Owner Check Audit

For each AccountInfo or UncheckedAccount usage:

AccountOwner Validated?Validation LocationCorrect Owner?Missing?
{name}YES/NO{line}{expected vs actual}FLAG if NO

Critical pattern: Any AccountInfo deserialized without prior owner check → arbitrary data injection. Anchor pattern: #[account(owner = expected_program)] or manual require!(account.owner == &expected_id).

3. Discriminator Check

For all accounts deserialized from raw data:

AccountUses Account<T>?Discriminator Checked?Can Substitute Different Account Type?
{name}YES/NOYES/NO (Anchor auto){if NO: what types could be substituted}

Attack: Pass an account of Type B where Type A is expected - different data layout, fields interpreted incorrectly. Safe: Anchor's Account<T> checks the 8-byte discriminator. Manual programs must check explicitly.

Anchor IDL buffer amplification: If the program uses Anchor with the default IDL feature enabled (check Cargo.toml for idl-build feature or absence of no-idl — enabled by default), IdlCreateBuffer is a permissionless instruction that lets ANYONE create program-owned accounts with nearly arbitrary data at arbitrary lengths. This means a missing discriminator check is exploitable even when no other account type in the program has a suitable layout for cosplay — the attacker crafts one via IdlCreateBuffer. When flagging a discriminator bypass: if IDL feature is enabled, severity is NOT mitigated by "no suitable account type exists for substitution."

4. Data Matching (Cross-Account References)

For each cross-account reference (has_one, constraint, seeds):

InstructionAccount AAccount BRelationshipValidated?Bypass?
{ix}{a}{b}{a.field == b.key()}YES/NO{if NO: how to exploit}

Pattern: Ensure that when Account A references Account B (e.g., vault.mint == mint.key()), the relationship is enforced on-chain. Attack: Substitute a different mint account that the vault doesn't actually belong to.

5. Remaining Accounts Audit

For each use of ctx.remaining_accounts:

InstructionRemaining Account UsageOwner Validated?Type Validated?Signer Checked?Data Validated?
{ix}{purpose}YES/NOYES/NOYES/NOYES/NO

Critical: remaining_accounts bypass Anchor's automatic validation. Every field must be checked manually. Attack: Inject attacker-controlled accounts via remaining_accounts to redirect funds or corrupt state.

Show full SKILL.md (260 more words)Show less

6. Duplicate Account Detection

For each instruction with 2+ mutable accounts:

InstructionMutable Account AMutable Account BKey Uniqueness Enforced?Self-Transfer Risk?
{ix}{a}{b}YES/NO{if NO: impact of a==b}

Attack (S7): Pass the same account as both from and to in a transfer → potential balance inflation. Defense: require!(account_a.key() != account_b.key()) or Anchor constraint.

7. Sysvar Validation

For each sysvar account passed as input:

SysvarPassed AsAddress Validated?Could Be Spoofed?
ClockAccountInfoYES/NO{if NO: attacker controls time}
RentAccountInfoYES/NO{if NO: attacker controls rent}
InstructionsAccountInfoYES/NO{if NO: Wormhole-style attack}

Safe pattern: Use Sysvar::from_account_info() or _checked variants. Unsafe pattern: Raw deserialization of sysvar data from unchecked AccountInfo.

8. Trust Chain Analysis

For each account validation chain, trace to its root:

AccountValidated AgainstRoot Trust AnchorChain Complete?
{account}{what validates it}PDA / Program ID / Hardcoded pubkey / NONEYES/NO

Pattern: Validation chain must root in a known-good value. If chain roots in user input → FINDING. Example: authority validated against vault.authority, vault validated against PDA seeds → chain roots in PDA (good).

Finding Template

markdown
**ID**: [AV-N]
**Severity**: [based on what attacker can do with invalid account]
**Step Execution**: ✓1,2,3,4,5,6,7,8 | ✗(reasons) | ?(uncertain)
**Rules Applied**: [S1:✓, S6:✓/✗, S7:✓/✗, S8:✓/✗, R4:✓/✗]
**Location**: program/src/instructions/{file}.rs:LineN
**Title**: Missing [validation type] for [account] in [instruction] enables [attack]
**Description**: [Specific missing validation with code reference]
**Impact**: [What attacker can achieve: fund theft, state corruption, DoS]

Step Execution Checklist (MANDATORY)

SectionRequiredCompleted?Notes
1. Account Type InventoryYES✓/✗/?For every instruction
2. Owner Check AuditYES✓/✗/?For every AccountInfo/UncheckedAccount
3. Discriminator CheckYES✓/✗/?For all deserialized accounts
4. Data MatchingYES✓/✗/?For all cross-account references
5. Remaining Accounts AuditIF remaining_accounts used✓/✗(N/A)/?Manual validation check
6. Duplicate Account DetectionYES✓/✗/?For all mutable account pairs
7. Sysvar ValidationIF sysvars passed as AccountInfo✓/✗(N/A)/?Address validation
8. Trust Chain AnalysisYES✓/✗/?Chain to root trust anchor

© PlamenTSV, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in agents/skills/solana/account-validation of PlamenTSV/plamen.

Open the folder on GitHubat commit 795962b

Compare with similar skills

Account Validation next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Account Validation compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Account Validation this skillPlamenTSV/plamen303—~1.7kAutomated safety check: PassMIT
Minara Crypto Trading and WalletMinara-AI/minara-skills3581 repos~5.7kAutomated safety check: PassNone
NEAR Intents Swap Integrationinternet-court/internet-court-skill6.4k2 repos~939Automated safety check: PassCustom licence
Solana Devsolana-foundation/solana-dev-skill574—~3.8kAutomated safety check: PassMIT
Meme Coin Security Auditawarexone/Agentic-Bug-Hunter5.3k1 repos~2.4kAutomated safety check: PassMIT
Swapper Depositswapperfinance/swapper-toolkit852—~1.8kAutomated safety check: PassMIT

Similar skills

  • Minara Crypto Trading and Wallet

    Minara-AI/minara-skills

    Drives the Minara CLI for crypto swaps, perps, limit orders, wallet transfers, deposits and withdrawals, plus AI market analysis.

    358 GitHub starsUsed in 1 repo~5.7k tokens
    Business, Finance & HRAuto-check passed
  • NEAR Intents Swap Integration

    internet-court/internet-court-skill

    Builds cross-chain token swaps and bridge flows with the NEAR Intents 1Click API: quotes, deposit addresses, per-chain deposits and status polling.

    6.4k GitHub starsUsed in 2 repos~939 tokens
    Backend & APIsAuto-check passed
  • Solana Dev

    solana-foundation/solana-dev-skill

    A skill your agent uses when user asks to "build a Solana dapp", "write an Anchor program", "create a token", "debug Solana errors", "set up wallet connection", "test my Solana program", "fuzz my…

    574 GitHub stars~3.8k tokensUpdated yesterday
    Backend & APIsAuto-check passed
  • Meme Coin Security Audit

    awarexone/Agentic-Bug-Hunter

    Screens EVM and Solana meme coins for rug pull signs such as hidden mint, honeypot logic and fee tricks, starting with fast kill signals before any code review.

    5.3k GitHub starsUsed in 1 repo~2.4k tokens
    SecurityAuto-check passed
  • Swapper Deposit

    swapperfinance/swapper-toolkit

    Deposit and bridge funds into a wallet or protocol using Swapper Finance.

    852 GitHub stars~1.8k tokensUpdated 6 mo ago
    Business, Finance & HRAuto-check passed
  • PNP Prediction Markets on Solana

    internet-court/internet-court-skill

    Creates, trades and settles permissionless prediction markets on Solana with any SPL token as collateral, including social-media and custom-oracle markets.

    6.4k GitHub stars~7.5k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check: notes

More from PlamenTSV/plamen

All 87 skills in this repo
  • Audit Prep

    PlamenTSV/plamen

    Prepare Solidity projects for a security audit — test coverage, test quality, NatSpec docs, code hygiene, dependency health, best-practice enforcement, deployment readiness, and project…

    303 GitHub stars~3.7k tokensUpdated 12 days ago
    Auto-check passed
  • Verification Protocol

    PlamenTSV/plamen

    Trigger Pattern Always (used by all verifier agents) - Inject Into security-verifier agents (Phase 5)

    303 GitHub stars~3.5k tokensUpdated 12 days ago
    Auto-check passed
  • Ability Analysis

    PlamenTSV/plamen

    Trigger Pattern Always (Aptos Move) - foundational security check - Inject Into Breadth agents, depth agents

    303 GitHub stars~3.3k tokensUpdated 12 days ago
    Auto-check passed
  • Ability Analysis

    PlamenTSV/plamen

    Trigger Pattern Always (Sui Move) -- foundational security check - Inject Into Breadth agents, depth agents

    303 GitHub stars~3.2k tokensUpdated 12 days ago
    Auto-check passed
  • Account Lifecycle

    PlamenTSV/plamen

    Trigger Pattern ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents, depth agents

    303 GitHub stars~1.2k tokensUpdated 12 days ago
    Auto-check passed
  • Auth Validation

    PlamenTSV/plamen

    Trigger Pattern Always required for Soroban audits - Inject Into Breadth agents, depth agents

    303 GitHub stars~2.2k tokensUpdated 12 days ago
    Auto-check passed

Works with

Questions about Account Validation

What does Account Validation do?

Trigger Pattern Always required for Solana audits - Inject Into Breadth agents, depth agents. Account Validation is an agent skill from PlamenTSV/plamen.

When should I use Account Validation?

Account Validation fits situations like: pattern Always required for Solana audits - Inject Into Breadth agents.

How do I install Account Validation in Claude Code?

Run `npx skills add PlamenTSV/plamen --skill account-validation -a claude-code`. Or copy the skill folder (agents/skills/solana/account-validation in PlamenTSV/plamen) into .claude/skills/account-validation in your project. Claude Code loads it when a task matches its description.

How do I install Account Validation in Codex?

Run `npx skills add PlamenTSV/plamen --skill account-validation -a codex`. Or copy the skill folder (agents/skills/solana/account-validation in PlamenTSV/plamen) into .agents/skills/account-validation in your project. Codex loads it when a task matches its description.

Can I use Account Validation in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add PlamenTSV/plamen --skill account-validation -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/account-validation, .gemini/skills/account-validation, .github/skills/account-validation and .opencode/skills/account-validation in your project.

What does Account Validation need to run?

SKILL.md names no scripts, command-line tools or credentials: Account Validation is instructions for the agent only.

Does Account Validation access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Account Validation safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Account Validation use?

Account Validation is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Account Validation use?

About 1.7k tokens (SKILL.md is roughly 6.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Account Validation?

Skills that share tags, products or a category with Account Validation: Minara Crypto Trading and Wallet (Minara-AI/minara-skills, 358 stars), NEAR Intents Swap Integration (internet-court/internet-court-skill, 6.4k stars), Solana Dev (solana-foundation/solana-dev-skill, 574 stars) and Meme Coin Security Audit (awarexone/Agentic-Bug-Hunter, 5.3k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Account Validation?

PlamenTSV (a GitHub user) maintains it in PlamenTSV/plamen, which has 303 GitHub stars. The repository holds 87 skills in this directory. The repository was last updated on September 26, 2026.

Source: PlamenTSV/plamen on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.