阻止 TransitSwap 攻击:行业首个“黑客反击”拯救 30 万美元

阻止 TransitSwap 攻击:行业首个“黑客反击”拯救 30 万美元

自 BlockSec 于 2021 年首次亮相以来,我们一直认为代码审计本身无法解决 Web3 安全问题。因此,我们一直在投资探索 Web3 安全的新范式。因此,我们创建了 Phalcon,这是世界上第一个加密货币黑客阻止系统。

在 Phalcon 推出之前,该系统已在内部运行了 2 年,成功阻止了 20 多起黑客攻击,并挽救了价值超过 2000 万美元的资产,其中包括为 Saddle Finance 挽救的 380 万美元,为 Platypus 挽救的 240 万美元,为 ParaSpace 挽救的 500 万美元,以及更多。

在本系列文章中,我们将展示我们系统 Phalcon 的代表性成功案例。今天,让我们来看看行业首个挽救了 30 万美元的“反击”。

如何为 TransitSwap(和 BabySwap)追回被盗资金

攻击与防御之间不断演变的竞赛反映了现实世界的多元化和丰富多彩。我们的经验表明,主动威胁防护并非单一的独特技能;相反,它是一种系统性的方法,结合了各种安全技术和努力。

这个故事突出了网络安全的错综复杂,当我们回顾在 BSC 上 BabySwap 和 TransitSwap 攻击中的经历时。有关详细分析,请参阅我们之前的报告

Transit Swap 发布的更新
Transit Swap 发布的更新

2022 年 10 月 1 日,UTC 时间 14:47,我们的内部系统识别了一笔攻击交易。在我们的调查过程中,我们发现该交易是由一个机器人账户发起的,该账户通过抢跑了最初的攻击。该账户以八个前导零为特征,表明它是由易受攻击的 Profanity 工具生成的。

机会偏爱有准备的人,而我们已经开发了一个救援工具来恢复易受攻击的 Profanity 地址的私钥,这是基于我们之前的努力

到 UTC 时间 16:10,我们的工具在短短 20 分钟内迅速恢复了机器人的私钥。按照我们标准的救援程序,我们立即将资金转移到了一个安全账户。此措施确保了其他可能恢复私钥的人无法访问该账户并危及资金。

然而,我们面临一个障碍:资金在机器人部署的合约中,而不是在它的 EOA 账户中。通过反编译合约,我们找到了一个可以用来检索资金的 withdraw 函数(如下图所示)。

将代币地址作为第一个参数,零作为第二个参数,我们执行了一笔交易,成功地将资金从合约提取到机器人,然后将它们转移到我们的安全账户

几个小时后,我们的系统检测到TransitSwap 的又一次攻击。在多笔攻击交易中,有一笔再次被机器人抢跑。然而,由于机器人部署的合约与之前的合约不同,转移资金的函数也不同。

我们决定将资金归还给被攻击的项目(而不是机器人),原因如下:

  • 首先,机器人通过抢跑攻击交易获得了资金,我们认为这本身就是一种攻击;
  • 其次,这笔资金属于攻击的受害者,即受影响的 DeFi 协议的用户。这些用户已经因 DeFi 协议的漏洞而遭受损失,他们应该从攻击者那里收到资金。

这种系统性的方法在应对现实世界安全威胁方面给我们带来了巨大的好处,它强调了在不断变化的 Web3 安全领域进行持续学习和适应的重要性。

如何访问服务

  • Phalcon 是一个 SaaS 平台。您可以登录我们的网站来探索功能、查看定价并直接订阅。
  • 您还可以预约演示以了解更多关于 Phalcon 的信息并获得专家安全建议。

让 Phalcon 为您的协议构建一道防线。它不需要协议方付出很多工作,也不会带来额外的风险。它就像一个盾牌,提供额外的安全层。立即预约演示

查看更多 Phalcon 成功案例

关于 Phalcon

Phalcon 是 BlockSec 推出的一款攻击监控和自动阻止平台。该平台能够准确识别攻击并自动阻止它们。Phalcon 旨在为 Web3 项目提供全面的上线后安全保护,包括持续监控、攻击阻止和紧急响应,从而保护协议提供商、LP 和 DAO 组织参与者的链上资产。

迄今为止,Phalcon 已成功阻止了 20 多起黑客攻击,挽救了超过 2000 万美元的资产。即使在早期客户阶段,Phalcon 也获得了顶级 DeFi 协议 Compound 的认可和资助,并为其建立了攻击阻止平台。

网站:https://blocksec.com/phalcon

Twitter:@Phalcon_xyz

电报:https://t.me/BlockSecTeam

Sign up for the latest updates
Weekly Web3 Security Incident Roundup | Feb 9 – Feb 15, 2026

Weekly Web3 Security Incident Roundup | Feb 9 – Feb 15, 2026

During the week of February 9 to February 15, 2026, three blockchain security incidents were reported with total losses of ~$657K. All incidents occurred on the BNB Smart Chain and involved flawed business logic in DeFi token contracts. The primary causes included an unchecked balance withdrawal from an intermediary contract that allowed donation-based inflation of a liquidity addition targeted by a sandwich attack, a post-swap deflationary clawback that returned sold tokens to the caller while draining pool reserves to create a repeatable price-manipulation primitive, and a token transfer override that burned tokens directly from a Uniswap V2 pair's balance and force-synced reserves within the same transaction to artificially inflate the token price.

Top 10 "Awesome" Security Incidents in 2025

Top 10 "Awesome" Security Incidents in 2025

To help the community learn from what happened, BlockSec selected ten incidents that stood out most this year. These cases were chosen not only for the scale of loss, but also for the distinct techniques involved, the unexpected twists in execution, and the new or underexplored attack surfaces they revealed.

#10 Panoptic Incident: XOR Linearity Breaks the Position Fingerprint Scheme

#10 Panoptic Incident: XOR Linearity Breaks the Position Fingerprint Scheme

On August 29, 2025, Panoptic disclosed a Cantina bounty finding and confirmed that, with support from Cantina and Seal911, it executed a rescue operation on August 25 to secure roughly $400K in funds. The issue stemmed from a flaw in Panoptic’s position fingerprint calculation algorithm, which could have enabled incorrect position identification and downstream fund risk.