How a Bot Gained and Lost Over $1 Million of ETH in One Night

On Tuesday night, an Ethereum MEV bot gained 800 ETH through the use of clever arbitrage, only to lose all of it and more to a hacker an hour later.

Here’s how the situation played out on-chain:

  • The event began with a third-party trader mistakenly losing nearly $2 million to spreads on Uniswap v2 trade. While he initially traded in 1.8 million cUSDC, he only received 518 USDC in return. 
  • According to Flashbots Product Lead Robert Miller, this only created a “massive arbitrage opportunity” for another trader to swoop in and claim plenty of ETH.
  • “0xbaDc0dE [the MEV bot] dutifully backran the arb in the mempool (!) in a looong arb touching many protocols,” he explained. In the end, the bot netted 800 ETH. 
  • However, that ETH was entirely stolen just an hour later. Miller claims the bot didn’t properly protect the function it’s used to execute dydx flashloans, leaving it vulnerable.

“When you get a flashloan the protocol you’re borrowing from will call a standardized function on your contract,” he said. “0xbaDc0dE’s code unfortunately allowed for arbitrary execution.”

  • Using this vulnerability, an attacker approved all of the bot’s WETH for spending on the contract, then transferred it to his own address. That was 1,106 WETH in total, worth over $1.4 million at writing time. 
  • Numerous vanity addresses generated by Profanity have also been drained of roughly $1 million in ETH this month. 
SPECIAL OFFER (Sponsored)
Binance Free $100 (Exclusive): Use this link to register and receive $100 free and 10% off fees on Binance Futures first month (terms).

PrimeXBT Special Offer: Use this link to register & enter POTATO50 code to receive up to $7,000 on your deposits.

You Might Also Like:


.custom-author-info{ border-top:none; margin:0px; margin-bottom:25px; background: #f1f1f1; } .custom-author-info .author-title{ margin-top:0px; color:#3b3b3b; background:#fed319; padding:5px 15px; font-size: 20px; } .author-info .author-avatar { margin: 0px 25px 0px 15px; } .custom-author-info .author-avatar img{ border-radius: 50%; border: 2px solid #d0c9c9; padding: 3px; }

The post appeared first on CryptoPotato

Buy Bitcoin with Credit Card

BitMex Leverage Trading

Automated Trading Bot

Related Posts

Leave a Reply

Bitcoin (BTC) $ 98,165.30 0.64%
Ethereum (ETH) $ 3,424.16 2.14%
Tether (USDT) $ 1.00 0.14%
Solana (SOL) $ 258.09 0.85%
BNB (BNB) $ 659.08 1.92%
XRP (XRP) $ 1.47 2.65%
Dogecoin (DOGE) $ 0.438474 6.55%
USDC (USDC) $ 0.998956 0.19%
Cardano (ADA) $ 1.08 2.10%
Lido Staked Ether (STETH) $ 3,421.97 2.19%