Nerve Finance Hack

TOTAL LOST $586K
Low Other

Summarize with AI

Affected Chain 2021 Incident surface
Recovered - No recovery reported
All-Time Rank #966 By amount stolen
Auditors 1 Prior security audit

Incident Overview

The attacker:

https://bscscan.com/address/0xd5476194…d69228

The transaction behind the attack:

https://bscscan.com/tx/0xea95925e…6fcf1d

The attacker:

- borrowed 50,000 BUSD using a flash loan from Fortube

- swapped 50,000 BUSD for 50,351 fUSDT from Ellipsis

- invoked the swap function of MetaSwap to swap 50,351 fUSDT for 36,959 Nerve 3-LP with a relatively big slippage

- invoked the removeLiquidityOneCoin() function of Nerve.3pool with the LP tokens (received in the previous step) to remove the liquidity of BUSD, i.e., 37,071 BUSD

- invoked the swapUnderlying() function of MetaSwap to swap BUSD for fUSDT, and received 51,494 fUSDT.

The attacker repeatedly executed the above steps to drain the liquidity of the MetaPool and finally harvested 900 BNB.

Stolen funds were deposited into Tornado Cash mixer:

https://bscscan.com/tx/0xcf43eefb…0aec90

https://bscscan.com/tx/0x55bd06a0…190a53

https://bscscan.com/tx/0x2dbc18c6…23067b

https://bscscan.com/tx/0x17cd04cb…334e7c

https://bscscan.com/tx/0xe5a0a058…4fa1f4

https://bscscan.com/tx/0x16ec28d4…896581

https://bscscan.com/tx/0x7f6b4313…0bb3c1

The rest were bridged though AnySwap:

https://bscscan.com/tx/0x0348cc92…2332a6

The swap function ignores the impact of the virtual price, which means the value of the LP token will be underestimated and more LP tokens could be swapped out. As a result, it is possible to harvest more pool stablecoins by first fetching back the liquidity of the underlying stablecoins with the corresponding LP token, and then swapping pool stablecoins by invoking the swapUnderlying() function.

Incident Report

Protocol / Project Nerve Finance
Date of Incident
Attack Technique Other
Classification Exchange (DEX)

Protocol Information

Protocol Type Lending
Affected Token NRV
Official Website nerve.fi/
Protocol Twitter/X @NerveFinance
Team Anonymous
Source Code Unverified

Market Context at Time of Hack

Token Categories
DeFi Yield Farming AMM DEX Three Arrows Capital Portfolio BNB Chain Ecosystem

What the Attacker Needed to Succeed

Understanding the prerequisites for this type of attack helps auditors identify protocols that are most at risk and helps developers build better defenses.

Technical Knowledge Deep understanding of other and Solidity and EVM internals
Capital Required Seed capital to cover gas and initial position setup
On-Chain Access Ability to interact with smart contracts and deploy a custom exploit contract
Protocol Analysis Identification of the exploitable vulnerability in Nerve Finance's contract logic - root cause: exchange (dex)
Execution Speed Precise transaction ordering and timing to exploit the vulnerability within a single atomic block
Obfuscation Plan A strategy to launder and move stolen funds - typically through mixers, cross-chain bridges, or decentralized DEX swaps to resist tracing

What Auditors Should Check

Could this have been caught in audit? Likely — with a thorough Other audit checklist and test coverage
Audited by Audit Report 1 — still lost $586K. Prior audits don't guarantee safety, especially after post-audit code changes.

If you're auditing a protocol with similar architecture to Nerve Finance, these are the critical security checks that could have prevented this incident (November 2021).

  • Verify all logic paths related to Other are guarded by proper access controls and input validation
  • Review privileged functions (owner, admin, governance) for potential abuse vectors - centralization risks should be documented and bounded with timelocks or multi-sigs

Master these auditing techniques with hands-on labs and real exploit scenarios in the Smart Contract Hacking course.

Free Trial

Security Audit History

Sources & References

Learn to Prevent the Next Nerve Finance

The Nerve Finance hack is one of many attacks that skilled auditors are trained to detect before deployment. Master real exploit patterns and defense techniques with hands-on Web3 security training.

Recreate exploit patterns safely Free Trial