ONISWAP
Every pool is pressed with its maker's print.
An exchange on Solana where each pool runs its own program, a hook, before and after every swap.
Every pool is pressed with its maker's print.
An exchange on Solana where each pool runs its own program, a hook, before and after every swap.
Its own, and never a signature.
Before each swap the pool calls its hook, and the hook may answer with the fee this trade pays. After the swap the pool calls it again so it can record what happened. The hook is picked once, when the pool opens, and checked on every swap.
3,947 units for the hook called before and after one swap, on a local
Solana validator.
A Solana transaction may spend up to 1,400,000 units. The two hook calls use 0.28 percent of that.
Pick a hook, then send a swap
Empty the vault
The steel mask is the hook. Send it at the pool and see what it gets away with.
The hook tried to overwrite the reserves and failed, because it sees one account.
A hook can still stop swaps in its own pool, so the app shows each hook's program, who can upgrade it and who it pays. Read the security shape.