Security · Threat model

What Onleash stops.
What it doesn't.

This is the honest scope of v1. No security claims beyond what the code actually enforces on-chain today.

Audit status: not yet audited · devnet only

attack scenarios

Attacks Onleash blocks.

Attack
Jailbreak — destination redirect

Attacker tricks agent into sending to an unapproved address via prompt injection or LLM manipulation.

Onleash response

Hook checks destination against allowlist before any funds move. Transfer reverts atomically.

6001 DestinationNotAllowed
Attack
Single oversized exfiltration

Agent signs a single transfer for the full wallet balance in one transaction.

Onleash response

per_tx_max cap rejects any transfer above the configured ceiling.

6002 ExceedsPerTxMax
Attack
Gradual drain across many transfers

Agent makes many small transfers, each individually under per_tx_max, draining the wallet over time.

Onleash response

24h rolling daily_cap and max_transfers_per_day together bound total daily outflow.

6003 / 6009
Attack
Rapid-fire micro-drain

Agent submits hundreds of minimum-value transfers per second before daily cap is reached.

Onleash response

cooldown_secs enforces a minimum interval between transfers, regardless of amount.

6008 CooldownActive
Attack
pay.sh / x402 payment hijack

Jailbroken agent receives a fake HTTP 402 challenge from an attacker and routes payment there.

Onleash response

Attacker address is not in the allowlist. Hook rejects the transfer before settlement.

6001 DestinationNotAllowed
Attack
Emergency drain after incident

Suspicious activity detected — agent may be compromised and sending a stream of small transfers.

Onleash response

Authority sets paused=true in one transaction. All transfers halt immediately on-chain.

6007 PolicyPaused

honest limitations

What v1 does not protect.

These are real gaps. Knowing them lets you layer complementary defences.

Native SOL transfers

The hook only fires on Token-2022 transfers. A jailbroken agent holding SOL directly is not protected — it can send SOL to any address.

Mitigation: Hold value as policy-protected SPL tokens, not raw SOL

MintTo and Burn

Hook does not fire on MintTo or Burn instructions. If the agent is also the mint authority, it could mint additional supply or burn tokens to zero.

Mitigation: Revoke mint authority after initial issuance (v2 companion guard)

Legacy SPL Token mints

Transfer hooks are a Token-2022 extension. Existing SPL Token mints cannot be retrofitted — they need to be reissued as Token-2022.

Mitigation: Use deployProtectedMint to issue new Token-2022 mints

Approve + delegate transfers

If the agent approves a delegate and that delegate initiates a transfer, the hook fires and policy applies — but the agent can grant unlimited delegate authority.

Mitigation: Monitor or restrict Approve instructions (v2 companion guard)

CloseAccount

An agent can close its own token account and recover the rent lamports as SOL, bypassing the hook entirely.

Mitigation: Companion guard for CloseAccount (v2 roadmap)

Program upgrade

The Onleash program currently has a single upgrade authority (deployer keypair). A compromised deployer could modify the hook logic.

Mitigation: Squads 2-of-3 multisig upgrade authority — in progress

trust model

What you must trust for this to work.

Solana runtime

You trust Solana's Token-2022 program to invoke the hook correctly on every transfer. This is the foundational assumption — the hook is only as strong as the protocol that calls it.

Onleash program

You trust the deployed hook program implements the policy faithfully. Mitigated by open source code, 13 test cases, and a planned security audit.

Policy authority

You trust whoever holds the authority keypair to not maliciously update the policy. Mitigated by using a Squads multisig as authority instead of a single key.

audit status

Not yet audited.

Onleash v1 has not been audited by an independent security firm. The program is deployed on devnet only. Do not use it to protect real funds until a mainnet audit is complete. An OtterSec or Neodyme audit is planned before mainnet GA — see the roadmap.

See how the checks work.

Full execution flow and policy schema on the how-it-works page.