Old Bugs Die Hard: Exploiting the ParaSwap AugustusV6 Vulnerabili
The AugustusV6 swap router failed to properly verify who was calling its Uniswap V3 swap callback, so an attacker could craft a fake pool and swap to make the router pull a victim's approved USDC into that pool. The attacker then controlled the pool's liquidity and could withdraw roughly 20,000 USDC from a single victim address.
In this post, I’ll discuss a small hack I discovered using defimon alerts. https://defimon.xyz. A vulnerability(already a year old!)in the swap router (AugustusV6 + Uniswap V3 pool) allowed the theft of ~20,000 USDC from a single address.The main lesson is to remember about allowances.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the router's Uniswap V3 swap callback did not verify that the caller was a legitimate pool it had itself invoked, so an attacker-controlled pool could trigger the router to spend a victim's allowance.
Impact
About 20,107 USDC could be stolen from a single address that had granted an allowance to the router.
What the attacker needed
Victim granted USDC allowance to AugustusV6; attacker can deploy contracts and create a pool
How it was found
- Create a fake token and a Uniswap V3 pool pairing it with USDC, then initialise the pool price.
- Add liquidity to the pool in a narrow tick range so only the fake token is needed.
- Call the router's swap callback with crafted data so the router believes a legitimate swap is in progress.
- The router pulls the victim's approved USDC into the attacker's pool.
- Burn or collect the pool liquidity, or swap back, to take the USDC out.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
When you swap tokens on a decentralised exchange, you first give a router contract permission to spend your tokens, called an allowance. This router accepted a message from a fake trading pool without checking that the pool was genuine, so it moved the victim's tokens into the attacker's pool. The attacker then took the tokens out because they owned that pool.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.