MOD_08 // DATA_MATCHING

The Identity Theft — Create fake configs to bypass has_one checks

THE VULNERABILITY

Protocol uses has_one = admin to verify ownership. The bug: it validates data INSIDE the account, not the ACCOUNT ITSELF.

VULNERABLE
#[account(init, payer = admin)]
// No PDA seeds = anyone can create!
SECURE
seeds = [b"protocol_config"]
// PDA = only ONE config exists!

CONTROL PANEL

Connect wallet to interact

ATTACKER_TREASURY

Stolen via fake config fees
LOOTED TOKENS
0
tokens stolen as "fees"

PROTOCOL CONFIG

FEE RATE
---
Not initialized

USER BALANCE

BALANCE
---
tokens

SYSTEM LOGS

No logs yet...