损失超750万美元:针对MEV Bot的蜜罐攻击分析与被盗资金追踪

marsbitPublished on 2026-06-22Last updated on 2026-06-22

Abstract

6月21日,以太坊知名MEV机器人Jaredfromsubway.eth遭遇精心设计的蜜罐攻击,损失超750万美元。攻击者部署了一套复杂的合约组合,包括协调器、触发器、假代币及伪造交易对。其核心手段是通过构造虚假套利路径,在小额交易中正常消耗授权以降低怀疑,而在大额交易中保留机器人对真实代币(如USDC、USDT、WETH)的授权。随后,攻击者一次性调用所有保留的授权,将资产转移至自己地址。 攻击得手后,约287万USDC、204万USDT及1474枚ETH被盗。攻击者将大部分资产兑换为ETH并转移至四个地址,其中1000枚ETH已流入Tornado Cash。 此次事件揭示了一种针对MEV业务逻辑的高级攻击模式:不直接利用漏洞,而是诱骗机器人在看似正常的套利中留下关键授权。安全团队建议,机器人在面对陌生合约或自定义封装器时应极度谨慎,并需强制检查交易后的授权余额变化。

6月21日,以太坊网络上最活跃的MEV Bot之一 Jaredfromsubway.eth 遭遇了一次精心设计的“蜜罐攻击”(honeypot attack),损失超过750万美元的加密资产。以下是Beosin安全团队对此次攻击的分析与被盗资金流向追踪。

攻击流程分析

攻击合约族

- 协调器合约(0xb84db016324e8f2bfdd8dd9c260338aee0a8df52):负责记录当前区块是否处于 armed 状态,并在最终阶段循环调用子合约提取资金。- 触发器合约(0x4de8c729a064ff6087cc84a4152969349e4feb98):负责在同一区块内设置伪造的交易对状态,使套利路径看起来可执行。- 子合约 / 假代币合约:伪装成正常的 ERC-20 代币,用于获得真实的授权- Hub合约:负责支付少量真实收益,让MEV Bot觉得有利可图。- Ring V2 pair:伪造的Uniswap v2交易对。- 假中间代币合约:用于构造多跳套利路径,如 fCAP、fUSDC。

攻击的关键:诱骗授权

通过分析链上交易,攻击者构造了多组诱饵交易:

- 大额 USDC:机器人盈利约 36.997120 USDC,但留下 20 个 USDC 授权。- 大额 USDT:机器人盈利约 37.053440 USDT,但留下 20 个 USDT 授权。- 大额 WETH:机器人盈利约 0.0179 WETH,但留下 16 个 WETH 授权。- 小额交易则表现正常,授权在同一交易内被消耗,用于降低怀疑。

在小额交易中,机器人授权真实代币额度后,子合约会立即把真实代币转走,授权被消耗,看起来完全正常。

而大额交易中,子合约并不会调用 transferFrom 转移真实的代币,而是直接通过伪造交易对铸造假的代币。机器人以为自己完成了正常的 swap 前置步骤,但真实的代币授权仍然被保留。

这就是整个攻击的核心:小额交易正常消耗授权,大额交易保留授权。

攻击流程

以针对 USDC 的攻击交易为例:

(1)攻击者调用协调器,将当前区块设为 armed(2)攻击者调用触发器,更新多个伪造 Ring V2 pair 的状态(3)MEV Bot发现套利机会并执行交易

MEV Bot 交易内部大致流程如下:

(1)MEV Bot合约向某个子合约授权了大额的USDC额度(2)MEV Bot调用子合约的wrapTo/wrap函数(3)子合约因为当前状态为 armed,不消耗真实 USDC,而是向 pair 铸造假代币,USDC授权被保留(4)MEV Bot继续调用伪造 pair 的 swap(5)第二跳 pair 将代币发给MEV Bot(6)hub 合约向MEV Bot支付少量真实 USDC 利润

approval example

tx hash: 0x0121e07a916c06eea3e7daf11893f3f0b95b9e1684124545ae14c32aee6029bb

MEV Bot看到的结果:一笔成功的套利交易,获得了真实的USDC利润。但USDC的授权被子合约保留了下来。这类流程分别针对 USDC、USDT、WETH 重复执行,最终形成大量授权。

攻击交易哈希为:

0x2be8704f5a59b69e0b71f64aefdb99eb0e8ae9fb3926147c581910d71bcf3e65

攻击者调用协调器合约的drain loop,calldata 中包含 66 个子合约地址,以及MEV Bot合约地址。只要MEV Bot合约此前给子合约留下了额度授权,子合约就可以直接把对应真实代币转给攻击者。

最终结果:

- 20 个 USDC 大额授权被全部消耗- 16 个 WETH 大额授权被全部消耗- USDT的部分授权额度仍存在,但USDT余额已不足

资金流向分析

攻击得手后,攻击者地址(0x3e37f4A10d771Ba9dE44b6d301410b1BEdeA65d0)收到$2.87M USDC、$2.04M USDT和1,474 WETH。随后攻击者将稳定币兑换成ETH并转移至以下4个地址:

- 0xe3Da36E4bd1a5738fa5D6Ef4F0e4dF40bDeB5f17(约1,000 ETH)- 0x74Dc5b93586D248D5Aec64b3586736FF0A0D0e65(1,001 ETH)- 0xd8C125efCBc99408eC8723E9BBd81d1E8D39D845 (1,001 ETH)- 0x71d4416A7A85e08a5Fe7227Ca3B44Fc639e94e97(1,423 ETH)

其中0xe3Da3已转移1,000个ETH至Tornado Cash,其它三个地址的ETH未有进一步的转移。其资金流向图如下所示:

结语

本次攻击展示了一种高度精密的攻击方式:攻击者不直接攻击合约代码,而是根据MEV Bot的业务逻辑,通过构造对应的套利场景,从而误导MEV Bot做出看似无问题的授权,最后将其资产转移。对于套利机器人和 MEV Bot来说,不能只依赖模拟收益判断路线安全,尤其当套利路径中存在陌生合约、伪造 token 或自定义 wrapper 时,应当谨慎并且对交易后的allowance变化可考虑进行强制检查。

查看原文

Trending Cryptos

Related Questions

Q本次针对Jaredfromsubway.eth的蜜罐攻击中,攻击者的主要获利手段是什么?

A攻击者的主要获利手段是诱骗MEV Bot在构造的虚假套利路径中进行大额授权。他们通过小额交易正常消耗授权来麻痹机器人,在大额交易中则保留授权。最终,攻击者利用协调器合约调用这些被保留的授权,将MEV Bot合约中的真实资产(USDC、WETH、USDT)直接转走。

Q文章中提到的攻击核心“小额交易正常消耗授权,大额交易保留授权”是如何实现的?

A在攻击者构造的场景中,当MEV Bot执行小额套利交易时,授权给子合约的真实代币额度会在同一笔交易中被立即转走(消耗),使交易看起来正常。而在大额交易中,由于攻击合约处于“armed”状态,子合约不会调用transferFrom转移真实代币,而是铸造假代币来完成后续虚假的swap步骤。这导致MEV Bot以为交易成功,但授权额度却被完整保留下来,为后续攻击者转走资金留下了后门。

Q攻击得手后,被盗资金的主要流向是怎样的?

A攻击得手后,价值约750万美元的资金(包括USDC、USDT和WETH)首先汇集到攻击者地址0x3e37f4A10d771Ba9dE44b6d301410b1BEdeA65d0。随后,攻击者将稳定币兑换成ETH,并转移至四个不同的地址。其中,地址0xe3Da36E4bd1a5738fa5D6Ef4F0e4dF40bDeB5f17的约1000 ETH已被转移至Tornado Cash进行混币,另外三个地址的资金截至文章发布时尚未进一步转移。

Q根据文章分析,MEV Bot在此次攻击中暴露出的主要安全疏漏是什么?

AMEV Bot的主要安全疏漏在于其风险判断逻辑过于依赖交易模拟的收益结果,而忽略了交易执行后可能产生的风险状态变化。具体来说,它在执行套利交易前,只验证了路径的模拟收益为正,但没有在交易后强制检查或重置给陌生合约的授权额度,导致为攻击者子合约保留的大额授权成为巨大的安全隐患。

Q文章最后对MEV Bot等套利机器人提出了哪些安全建议?

A文章建议,套利机器人和MEV Bot不能仅依赖模拟收益来判断路径的安全性。特别是当套利路径中存在陌生合约、伪造代币或自定义封装合约时,应当保持高度谨慎。一个关键的安全措施是:在交易完成后,考虑对授权额度进行强制检查或重置,以防止授权被恶意保留和利用。

Related Reads

After Three Consecutive Quarters of Decline, Can the Crypto Market Find a Window for Stabilization in Q3?

The cryptocurrency market has just concluded its worst-performing quarter since 2022, with total capitalization dropping 12.6% to $2.1 trillion. All core metrics indicate capital is leaving the sector, not just rotating within it. Bitcoin fell 14.2% and Ethereum dropped 25.4% in Q2, breaking their previous correlation with US tech stocks. A key driver is the reversal in US spot Bitcoin ETF flows, which saw a net outflow of approximately $4.67 billion in Q2, including a record monthly outflow near $4.5 billion in June. While recent data suggests long-term holders are accumulating again, sustained ETF outflows mean continued selling pressure. Market focus is now singularly on the Federal Reserve. The upcoming July FOMC meeting is seen as the most critical event for Q3. A dovish signal could support Bitcoin reclaiming a $68,000-$84,000 range, while a hawkish stance might establish a new trading band around $50,000-$56,000. Additionally, regulatory uncertainty persists, with the progress of the crucial *CLARITY Act* stalling in the Senate, reducing its perceived 2026 passage probability to 40-45%. Despite the broad downturn, a few sectors showed growth. Prediction markets saw nominal volume surge 48.7% year-over-year to $113.8 billion, and tokenized collectibles transaction volume rose 143% quarterly to $1.4 billion. The Real-World Asset (RWA) tokenization sector also continued steady growth, now representing ~$28.1 billion in on-chain value. The market's foundation for an extreme crash appears limited, with Bitcoin price hovering near its 200-week moving average. However, the trading paradigm has shifted from narrative-driven speculation to decisions based on price action, policy developments, and interest rate expectations, making a broad sentiment-driven rally unlikely in the near term.

marsbitYesterday 08:36

After Three Consecutive Quarters of Decline, Can the Crypto Market Find a Window for Stabilization in Q3?

marsbitYesterday 08:36

BIT Trading Moment: BTC Still Suppressed by Weekly 200 EMA, Rejection May Restart Decline; Storage and Semiconductors that Surged Last Night Begin Falling in Evening Trading

**Crypto & Stock Market Wrap: Bitcoin Tests Resistance, Stocks Retreat After AI Surge** Bitcoin consolidates around $66,000, facing key resistance near $68,000—an area seen as a major psychological and technical hurdle where previous rallies have failed. Analysts note the cryptocurrency is caught between its 200-week moving average (~$63,333) and 200-week EMA (~$68,328). A clear break above $68k is needed to signal a stronger bullish trend, while a rejection could lead to a retest of $63k support. Market sentiment remains cautious, with low futures open interest pointing to a low-liquidity rebound rather than a full bull market. Bitcoin spot ETFs saw another $203 million inflow. US stock futures pointed lower after a strong Tuesday session led by a massive rebound in semiconductors and memory stocks. The rally was fueled by renewed optimism about AI-driven hardware demand, with Micron, SanDisk, and SK Hynix surging. However, those gains reversed in pre-market trading. Super Micro Computer (SMCI) soared over 20% after hours on strong guidance and a record backlog. Other standouts included Rocket Lab and nuclear energy plays Oklo and X-Energy. Rising oil prices (Brent above $91) and climbing Treasury yields (10-year near 4.64%), however, are reigniting inflation concerns and acting as a headwind for equities. In Asia, markets were mixed. South Korea's KOSPI pared early gains to close slightly higher as semiconductor stocks like SK Hynix gave back initial surges. Japan's Nikkei edged lower as the yen hit a fresh 38-year low against the dollar, raising fears of potential market intervention. Key events to watch include the Samsung Galaxy launch, AMD's AI event, and a slew of major tech earnings from Alphabet, Tesla, and IBM after the close on Wednesday, followed by the ECB meeting and Intel's earnings on Thursday.

marsbitYesterday 08:28

BIT Trading Moment: BTC Still Suppressed by Weekly 200 EMA, Rejection May Restart Decline; Storage and Semiconductors that Surged Last Night Begin Falling in Evening Trading

marsbitYesterday 08:28

Former CFTC Chairman, Circle President Tarbert: Preaching Long-Termism While Cashing Out $30 Million Himself

Former CFTC Chairman and Circle President Heath Tarbert has consistently advocated for a long-term vision in public, urging patience from investors as Circle’s stock price has fallen significantly from its peak. However, it has been revealed that since Circle’s IPO, Tarbert has continuously sold his CRCL shares through pre-arranged trading plans, cashing out approximately $30 million, without making any public market purchases. This contrast between his public messaging and personal actions has drawn criticism. Tarbert joined Circle in July 2023 as Chief Legal Officer, leveraging his regulatory experience to help guide the company through its IPO and expansion. Despite promoting stablecoins as long-term infrastructure, he established a 10b5-1 trading plan just before Circle went public, leading to substantial stock sales over the following year. In March 2026, he initiated another plan to sell more shares. His career trajectory highlights a pattern of moving between high-level regulatory roles and influential positions in the financial sector. After resigning as CFTC Chairman in early 2021, he joined Citadel Securities as Chief Legal Officer just 27 days later, during a period of intense regulatory scrutiny for the firm. He later joined Circle, aiding its efforts to navigate regulatory challenges for its public listing. While Tarbert's expertise in policy and compliance is valuable to companies like Circle, his actions—advocating long-term confidence while personally divesting—raise questions about the alignment between his public statements and his private financial decisions, leaving investors who followed his advice to bear the market risks.

marsbitYesterday 08:06

Former CFTC Chairman, Circle President Tarbert: Preaching Long-Termism While Cashing Out $30 Million Himself

marsbitYesterday 08:06

Gate Research Institute: The 'Wall Street-ization' Wave of Crypto Financial Products – Competition or Integration?

The article titled "Gate Research Institute: Are Crypto Financial Products Sparking a 'Wall Street' Wave—Competition or Convergence?" explores the evolving relationship between the crypto ecosystem and traditional finance (TradFi). The piece begins by reflecting on Bitcoin's original 2009 vision of decentralization, disintermediation, and moving away from banks. It then contrasts this with the 2024 landscape, where key crypto assets like Bitcoin are increasingly held through Wall Street products like ETFs issued by giants like BlackRock. The article questions whether this signifies that TradFi is systematically taking over the rights to issue, price, custody, and distribute crypto financial assets. The core argument is that this is not a zero-sum takeover but rather a bidirectional convergence where each side addresses the other's weaknesses. Crypto offers 24/7 global markets, programmable settlement, and open access but lacks compliant channels, institutional-grade custody, deep fiat liquidity, and mainstream distribution. TradFi possesses these but is constrained by legacy systems, limited operating hours, and slow settlement. Two primary convergence paths are highlighted: * **Path A (CEX to TradFi):** Exemplified by Gate, which has progressed from offering tokenized stocks and CFDs to providing direct, real stock trading (US, Hong Kong, South Korea) within its platform, using USDT. * **Path B (TradFi to Crypto):** Exemplified by Robinhood, which has integrated crypto trading, acquired exchanges like Bitstamp, and is moving traditional assets like stocks onto the blockchain via tokenization and its own Layer 2. Both paths are ultimately competing to become the next-generation, unified financial account—a "super account" where users can seamlessly trade cryptocurrencies, stocks, ETFs, RWA (Real World Assets), and tokenized treasury products in one interface. The growth of RWA and tokenized treasuries (e.g., BlackRock's BUIDL) is presented as the asset-layer fusion, providing stable, yield-bearing assets on-chain and acting as a bridge between the two worlds. In conclusion, the "Wall Street-ization" of crypto is framed as a mutual transformation. Decentralized ideals persist in the protocol layer, while at the application layer, a more efficient, global, and accessible unified capital market is emerging from this convergence. The future competition lies not between crypto exchanges and stockbrokers, but between platforms vying to offer the most comprehensive asset coverage, liquidity, and user experience within a single account.

marsbitYesterday 08:01

Gate Research Institute: The 'Wall Street-ization' Wave of Crypto Financial Products – Competition or Integration?

marsbitYesterday 08:01

Trading

Spot

Hot Articles

Discussions

Welcome to the HTX Community. Here, you can stay informed about the latest platform developments and gain access to professional market insights. Users' opinions on the price of ETH (ETH) are presented below.

活动图片