Skip to content
webdot
Web3 · SecurityPersonal project

RescueFi

Getting assets out of a hacked wallet before the bot gets its turn.

My role
All UI, contract integration and backend work.
Timeline
© 2026
Played with
Next.js, TypeScript, Viem, Wagmi, PostgreSQL, Solidity
Read time
1 min
Visit ↗
rescuefi.xyzRescueFi, annotated

Fig. 1 — RescueFi, annotated

  1. 1Paste the compromised key. It stays in the browser.
  2. 2Every move bundled into one transaction.
  3. 3The sweeper bot finds nothing to take.
Q1 · The situation

Every rescue attempt funded the thief.

When a private key leaks or a wallet gets hacked, the damage doesn't stop at what gets stolen first. Attackers usually leave a sweeper bot watching the address. The moment any native token lands for gas, the bot spends it, so the tokens, NFTs and unclaimed airdrops still in the wallet sit there in plain view and can't be moved.

The usual advice is to send gas and race the bot. You lose that race, and every attempt pays the attacker.

Q2 · The task

Get it all out without paying the bot.

Build a rescue tool that never sends gas to the compromised wallet: everything out in one transaction, on the chains people actually hold assets on, without asking anyone to hand their key over.

Q3 · What I did

Never put gas where the bot can reach it.

rescuefi.xyz
The live site, in use · on a loop

Delegate, don't deposit

EIP-7702 lets an ordinary wallet briefly act like a smart contract. The compromised wallet signs an authorisation pointing to a rescue contract I wrote, and a separate sponsor wallet pays the gas. The hacked wallet never holds anything the bot could take.

One bundle, one block

Every transfer goes into one transaction: up to 50 tokens and 50 NFTs to a safe address, executed together. There's no gap between steps for the bot to step into.

Signing in the browser

The two signatures are produced client-side with Viem and Wagmi. The backend receives the signatures and the rescue details, then assembles and submits the bundle.

Paid per rescue

Nobody who has just been robbed should pay up front. RescueFi takes 10% of each token it recovers, NFTs go free, referrers get 3%, and a testnet mode lets people rehearse first.

Q4 · The result

Fifteen chains, one transaction.

15+chains supported
1transaction per rescue

RescueFi is live on 15 mainnets, from Ethereum, Base and Arbitrum to Monad and MegaETH, plus 15 testnets.

Sound

Off. Nothing will make a peep.

Motion

Following your device: full motion.