📈 Get daily crypto insights that make you smarter about your money

Reentrancy Attacks on Legacy DeFi Contracts: How a Five-Year-Old Bug Drained $1.8 Million From Dolomite Users

On March 20, 2024, the cryptocurrency community witnessed yet another reminder that old code never truly dies — it just waits to be exploited. The Dolomite decentralized exchange, a protocol that had long since migrated its active operations to the Arbitrum layer-2 network, discovered that its original Ethereum-based smart contracts from 2019 were being drained by an attacker exploiting a classic reentrancy vulnerability. By the time the team disabled the old contract, approximately $1.8 million in user funds had already been siphoned and laundered through Tornado Cash.

The Exploit Mechanics

Reentrancy attacks remain one of the oldest and most devastating vulnerabilities in smart contract security. In the Dolomite incident, the attacker identified that the legacy contract — deployed in 2019, before many modern security standards were established — contained a function that allowed external callbacks before the contract’s internal state was updated. This is the textbook definition of a reentrancy vulnerability: the attacker’s contract could repeatedly call the withdrawal function before the balance was decremented, effectively withdrawing the same funds multiple times.

The attack specifically targeted users who had previously granted token approvals to the old Dolomite contract. Even though the exchange had moved its primary operations to Arbitrum, the Ethereum mainnet contract remained live and accessible. Users who had approved the old contract months or even years earlier were still exposed, as token approvals on Ethereum persist indefinitely unless manually revoked. With Bitcoin trading around $67,900 and Ethereum near $3,513 at the time, the $1.8 million loss represented a significant but not catastrophic event — yet it highlighted a systemic issue in DeFi.

Affected Systems

The Dolomite exploit was not an isolated incident on March 20, 2024. The same day, the DeFi aggregator ParaSwap disclosed a vulnerability in its newly launched Augustus V6 contract. While ParaSwap’s team acted quickly — pausing the V6 API and conducting a white hat recovery operation — the vulnerability still resulted in approximately $24,000 in losses across Polygon, Arbitrum, and Ethereum Mainnet. The ParaSwap incident stemmed from a different root cause: improper handling of the uniswapV3SwapCallback function, which allowed unauthorized redirection of funds through controllable parameters.

Together, these two incidents underscore a troubling pattern. In Dolomite’s case, the vulnerable code was five years old. In ParaSwap’s case, the contract had been live for only two days. The threat surface spans from legacy contracts that developers have forgotten about to brand-new deployments that haven’t been battle-tested. Both cases targeted users who had granted token approvals — a fundamental mechanism in DeFi that most users treat as routine.

The Mitigation Strategy

Dolomite responded by immediately disabling the legacy contract and urging all users who had ever interacted with the old version to revoke their token approvals. ParaSwap took similar action, pausing its V6 API and conducting white hat operations to secure at-risk funds before malicious actors could exploit them. Both teams emphasized the same message: check your approvals regularly.

For the broader DeFi ecosystem, these incidents reinforce several critical mitigation strategies. First, protocols should implement formal sunset procedures for legacy contracts, including explicit disable functions that prevent any future interaction. Second, users should periodically audit their active token approvals using tools like Revoke.cash or Etherscan’s token approval checker. Third, developers should adopt the checks-effects-interactions pattern — updating internal state before making external calls — to prevent reentrancy in new contracts.

Lessons Learned

The Dolomite exploit teaches a painful lesson about technical debt in DeFi. Smart contracts are immutable by design, which means vulnerabilities in old code can persist indefinitely. The protocol had moved on, but the contract had not. Users who interacted with Dolomite in 2019 may not have even remembered granting approvals, yet those permissions remained active for half a decade.

From a security perspective, the incident demonstrates that the DeFi ecosystem’s attack surface grows with every deployed contract, not just the active ones. Security researchers and attackers alike are increasingly scanning for forgotten contracts with known vulnerability patterns. The $1.8 million stolen from Dolomite represents just one successful discovery — there are likely many more legacy contracts with similar issues waiting to be found.

User Action Required

If you have ever interacted with Dolomite’s legacy Ethereum contract, ParaSwap’s Augustus V6, or any DeFi protocol that has since migrated to a new contract version, take immediate action. Navigate to Revoke.cash, connect your wallet, and review all active approvals. Revoke any approvals for contracts you are no longer actively using. This simple step takes minutes and can prevent devastating losses. In a market where Bitcoin hovers near $68,000 and DeFi total value locked exceeds $80 billion, the few minutes spent auditing your approvals could be the most profitable investment you make today.

Disclaimer: This article is for informational purposes only and does not constitute financial or investment advice. Always conduct your own research before making any financial decisions.

🌱 FOR BUSINESSES BitcoinsNews.com
Reach 100K+ Crypto Readers
Sponsored content, press releases, banner ads, and newsletter placements. Put your brand in front of Bitcoin's most engaged audience.

10 thoughts on “Reentrancy Attacks on Legacy DeFi Contracts: How a Five-Year-Old Bug Drained $1.8 Million From Dolomite Users”

  1. 2019 contract sitting there for 5 years with nobody watching it. this is why you revoke old approvals people

    1. ^ seriously, set a calendar reminder every 6 months to clean up your token approvals. takes 5 minutes on revoke.cash

      1. revoked mine after reading this. had old Dolomite approvals sitting in my wallet from 2020. thanks for the reminder

    2. sunset_proxy_

      5 year old contract with no sunset clause and no monitoring. the team migrated to arbitrum and just forgot the old stuff existed. amateur hour

  2. $1.8M through a textbook reentrancy. nothing new under the sun, just old code nobody bothered to deprecate

    1. textbook reentrancy from 2019 code. the vulnerability checklist for auditors has had this as item #1 since the DAO hack. zero excuse

      1. the DAO hack was 2016 and reentrancy was lesson #1. a 2019 contract with the same bug means either the audit missed it or there was no audit at all

        1. read the post-mortem, there was an audit but it was for the v2 contracts on arbitrum. the legacy ethereum contracts were never scoped

  3. 5 years untouched and nobody from the team thought to sunset the old contract. that is negligence not a hack

    1. deprecating old contracts should be standard practice after a migration. leaving live contracts with real funds sitting unmonitored is asking for trouble

Leave a Comment

Your email address will not be published. Required fields are marked *

BTC$65,310.00-0.8%ETH$1,763.31-1.0%SOL$73.07-0.4%BNB$603.03-0.5%XRP$1.20-0.9%ADA$0.1689-3.0%DOGE$0.0865-0.5%DOT$1.02+2.0%AVAX$6.88+1.5%LINK$8.22+0.4%UNI$3.29+8.5%ATOM$1.99+0.2%LTC$45.39+1.3%ARB$0.0870+2.9%NEAR$2.34+0.5%FIL$0.8177+4.5%SUI$0.7937+1.5%BTC$65,310.00-0.8%ETH$1,763.31-1.0%SOL$73.07-0.4%BNB$603.03-0.5%XRP$1.20-0.9%ADA$0.1689-3.0%DOGE$0.0865-0.5%DOT$1.02+2.0%AVAX$6.88+1.5%LINK$8.22+0.4%UNI$3.29+8.5%ATOM$1.99+0.2%LTC$45.39+1.3%ARB$0.0870+2.9%NEAR$2.34+0.5%FIL$0.8177+4.5%SUI$0.7937+1.5%
Scroll to Top