Agent skill

Account Lifecycle

by PlamenTSV in PlamenTSV/plamen

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

MITAuto-check passed

Install Account Lifecycle

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

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

GitHub CLI
$ gh skill install PlamenTSV/plamen account-lifecycle --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-lifecycle .claude/skills/account-lifecycle && 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-lifecycle
GitHub stars
303
Token cost
~1.2k tokens
SKILL.md length
453 words
Files
1
Skills in repo
87
Repo updated
First seen
Licence
MIT

At a glance

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

  • Works in 6 steps: Close Operation Inventory → Close Completeness → Revival Attack Analysis (S4 - CRITICAL) → …
  • Pattern ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents
  • SKILL.md covers 1. Close Operation Inventory, 2. Close Completeness, 3. Revival Attack Analysis (S4… and 4. Rent Recovery, plus 4 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Account Lifecycle is an agent skill from PlamenTSV/plamen. Trigger Pattern ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents, depth agents

Its SKILL.md is about 1.2k 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 ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents

Example prompts

  • “/account-lifecycle”

Workflow steps

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

  1. Close Operation Inventory
  2. Close Completeness
  3. Revival Attack Analysis (S4 - CRITICAL)
  4. Rent Recovery
  5. Token Account Closure
  6. Reinitialization Prevention

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 Lifecycle loads about 1.2k tokens when it runs. Until then it costs about 33 tokens; SKILL.md has 453 words of instructions outside code blocks.

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

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). 453 words, ~1,190 tokens.

Download SKILL.mdSave it as .claude/skills/account-lifecycle/SKILL.md (or your agent's skills folder).
name
account-lifecycle
description
Trigger Pattern ACCOUNT_CLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents, depth agents

ACCOUNT_LIFECYCLE Skill

Trigger Pattern: ACCOUNT_CLOSING flag detected (close/CloseAccount usage) Inject Into: Breadth agents, depth agents Finding prefix: [AL-N] Rules referenced: S4, R9

For every account close operation in the Solana program:

1. Close Operation Inventory

List all account closing operations:

#InstructionAccount ClosedClose MethodLamport RecipientLocation
1{ix}{account}Anchor close / manual{recipient}{file:line}

2. Close Completeness

For each close operation, verify ALL steps:

Close OpData Zeroed?Lamports Transferred?Discriminator Set to CLOSED?Owner Transferred to System?
{op}YES/NOYES/NOYES/NOYES/NO

Anchor close: Handles all 4 steps automatically. Manual closing MUST do all 4. Missing step impact:

  • Data not zeroed → residual data readable by other programs
  • Lamports not fully transferred → rent-exempt lamports stranded (Rule 9)
  • Discriminator not set → account can be "reopened" with stale type
  • Owner not transferred → program still has authority over closed account

3. Revival Attack Analysis (S4 - CRITICAL)

For each close operation:

Close OpSame-Tx Refund Possible?Revival Guard?Attack Sequence
{op}YES/NOYES/NO{if YES: describe}

Attack (S4): Within the SAME transaction, after an account is closed (lamports drained, data zeroed):

  1. Close account (lamports go to attacker)
  2. In same tx, re-fund account with lamports (becomes rent-exempt again)
  3. Account data is all zeros but account exists again
  4. Next instruction that checks account.data_len() > 0 or assumes "closed accounts don't exist" fails

Defense: Set discriminator to a CLOSED sentinel value. Check discriminator on every access, not just data length.

4. Rent Recovery

For each close operation:

AccountRent-Exempt LamportsFully Recovered?Recipient Correct?
{account}{amount}YES/NO{who gets the lamports}

Check: Are ALL lamports transferred? Partial transfer leaves lamports stranded.

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

5. Token Account Closure

For each SPL Token account closure:

Token AccountBalance Checked Zero?Withheld Fees Harvested? (Token-2022)Close Authority Correct?
{account}YES/NOYES/NO/N/A{who can close it}

SPL Token rule: Token accounts can only be closed when balance == 0. Token-2022: Accounts with TransferFeeConfig may have withheld fees. Must harvest before close.

6. Reinitialization Prevention

For each account type that can be initialized:

Account TypeInit MethodCan Be Re-Initialized?Guard
{type}init / init_if_needed / manualYES/NO{what prevents it}

init_if_needed WARNING: This attribute allows reinitialization if the account already exists. It is a known footgun. Safe pattern: Use init (fails if account exists) + manual is_initialized flag for manual programs. Attack: Re-initialize an account to reset its state (e.g., reset reward counter, change authority).

Finding Template

markdown
**ID**: [AL-N]
**Severity**: [revival = High, stranded rent = Medium, reinit = High]
**Step Execution**: ✓1,2,3,4,5,6 | ✗(reasons) | ?(uncertain)
**Rules Applied**: [S4:✓, R9:✓/✗]
**Location**: program/src/{file}.rs:LineN
**Title**: [Lifecycle issue] in [instruction] enables [attack]
**Description**: [Specific lifecycle vulnerability with code trace]
**Impact**: [Fund theft via revival / stranded assets / state reset]

Step Execution Checklist (MANDATORY)

SectionRequiredCompleted?Notes
1. Close Operation InventoryYES✓/✗/?For every close
2. Close CompletenessYES✓/✗/?All 4 steps verified
3. Revival Attack AnalysisYES✓/✗/?CRITICAL - same-tx refund
4. Rent RecoveryYES✓/✗/?Full lamport transfer
5. Token Account ClosureIF token accounts closed✓/✗(N/A)/?Balance + withheld fees
6. Reinitialization PreventionYES✓/✗/?init_if_needed is dangerous

© 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-lifecycle of PlamenTSV/plamen.

Open the folder on GitHubat commit 795962b

Compare with similar skills

Account Lifecycle 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 Lifecycle compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Account Lifecycle this skillPlamenTSV/plamen303—~1.2kAutomated 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 Validation

    PlamenTSV/plamen

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

    303 GitHub stars~1.7k 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 Lifecycle

What does Account Lifecycle do?

Trigger Pattern ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents, depth agents. Account Lifecycle is an agent skill from PlamenTSV/plamen.

When should I use Account Lifecycle?

Account Lifecycle fits situations like: pattern ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents.

How do I install Account Lifecycle in Claude Code?

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

How do I install Account Lifecycle in Codex?

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

Can I use Account Lifecycle 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-lifecycle -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-lifecycle, .gemini/skills/account-lifecycle, .github/skills/account-lifecycle and .opencode/skills/account-lifecycle in your project.

What does Account Lifecycle need to run?

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

Does Account Lifecycle 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 Lifecycle 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 Lifecycle use?

Account Lifecycle 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 Lifecycle use?

About 1.2k tokens (SKILL.md is roughly 4.8k 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 Lifecycle?

Skills that share tags, products or a category with Account Lifecycle: 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 Lifecycle?

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.