Aurora Inflation Spend Bug Fix Review 6m Payout
Aurora's Rainbow Bridge had an infinite spend bug where a malicious contract could use delegatecall to the ExitToNear precompile to generate withdrawal promises without actually sending ETH, allowing the attacker to double their balance repeatedly. This could have led to a direct loss of 70k ETH and $200m in other assets.
immunefi.com
Published on immunefi.com
Whitehat pwning.eth submitted a critical vulnerability in Aurora on April 26 via Immunefi. The vulnerability consisted of an infinite spend bug that, if exploited by a malicious user, could have led to a direct loss of 70k ETH and $200m in other assets.
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
The code only checked that a log event was generated by the built-in ExitToNear address and assumed msg.value > 0 meant ETH was sent, but delegatecall inherits msg.value from the caller without transferring ETH.
Impact
If exploited, the bug could have led to a direct loss of 70k ETH and $200m in other assets, but no user funds were lost because the bug was responsibly disclosed and patched.
What the attacker needed
Ether on Ethereum to bridge; Ability to deploy a contract on Aurora
The fix
An exit error is now returned if the address given does not match the inputs’ address, which disables the ability to call the contract with DELEGATECALL.
How it was found
- Bridge Ether from Ethereum to Aurora using Rainbow Bridge
- Deploy a malicious contract on Aurora that makes a delegatecall to the native contract ExitToNear
- Call the exploit function of the malicious contract, tricking Aurora into sending nETH to the caller on NEAR without changing the attacker's balance on Aurora
- Deposit the nETH back into Aurora, doubling the attacker's balance
- Repeat from step 3
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.
Aurora is a system that lets you move cryptocurrency between different blockchains. A flaw in how it handled a special instruction called delegatecall meant someone could trick it into thinking they had sent money when they hadn't, letting them create free money and repeat the trick to drain funds.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.