YB Token Sandwich Attack Due To No Slippage Protection
Notice: This page is a freshly imported case study from an original repository. While the original content had a similar format, some sections may not have been fully completed. Please help fill in any empty sections or any missing information you can find. If you are new here, please read General Tutorial on Wikis or Anatomy of a Case Study for help getting started.
Notice: This page contains sources which are not attributed to any text. The unattributed sources follow the initial description. Please assist by visiting each source, reviewing the content, and placing that reference next to any text it can be used to support. Feel free to add any information that you come across which isn't present already. Sources which don't contain any relevant information can be removed. Broken links can be replaced with versions from the Internet Archive. See General Tutorial on Wikis, Anatomy of a Case Study, and/or Citing Your Sources Guide for additional information. Thanks for your help!
The YB token smart contract, launched on May 18th, 2024, had a vulnerability in its _tokenTransfer function, which automatically triggers a bot to perform token swaps without proper slippage protection. This flaw allowed attackers to manipulate token prices in the liquidity pool and execute sandwich attacks to profit from the bot's unprotected swaps. One such attack, recorded under transaction ID 0xe1e7...a28b, resulted in an estimated loss of $15.3k, as reported by TenArmor. The attack was detected by VeriChain and TenArmor, but the identity behind the YB contract remains unknown, and there is no indication that any funds have been recovered or that further investigation is underway.[1][2][3][4][5][6][7]
About YB Smart Contract
The YB token smart contract was first launched on May 18th, 2024.
The Reality
Unfortunately the YB smart contract triggers swaps without proper slippage protection.
What Happened
The YB token contract, launched in May 2024, contained a slippage vulnerability that enabled sandwich attacks during automated swaps, resulting in a $15.3k loss.
Date | Event | Description |
---|---|---|
May 18th, 2024 7:58:35 AM MDT | YB Smart Contract Created | The YB smart contract is originally launched on the Binance Smart Chain. |
April 16th, 2025 12:21:29 PM MDT | Sandwich Attack Transaction | The sandwich attack transaction happens on the Binance Smart Chain YB smart contract. |
April 16th, 2025 7:49:00 PM MDT | TenArmor Posting Tweet | TenArmor posts details about the exploit including the attack transaction on the Binance Smart Chain. |
Technical Details
The YB Token contract automatically triggers a bot to perform token swaps during transfers, but it lacks slippage protection. This vulnerability allows attackers to manipulate prices and execute sandwich attacks to profit from the bot’s unprotected swaps.
The YB Token contract has an automated feature in its _tokenTransfer function that triggers a bot contract to perform swaps—swapBuy when users sell, and swapSell when they buy.
However, this automation lacks slippage protection, creating a vulnerability. Attackers can exploit this by manipulating token prices in the liquidity pool with small trades, then launching sandwich attacks—placing their own trades before and after the bot’s unprotected swap—to profit from the resulting price difference.
Transaction ID: 0xe1e7fa81c3761e2698aa83e084f7dd4a1ff907bcfc4a612d54d92175d4e8a28b
Total Amount Lost
TenArmor reports an approximate loss of $15.3k.
The total amount lost has been estimated at $15,000 USD.
Immediate Reactions
It is unclear who is behind the BY smart contract.
Ultimate Outcome
The sandwich attack was noticed and details were captured by VeriChain and TenArmor.
Total Amount Recovered
There is no indication that any funds have been recovered.
There do not appear to have been any funds recovered in this case.
Ongoing Developments
It is unclear if any further investigation is ongoing, or there is any hope of recovering funds.
Individual Prevention Policies
No specific policies for individual prevention have yet been identified in this case.
For the full list of how to protect your funds as an individual, check our Prevention Policies for Individuals guide.
Platform Prevention Policies
Policies for platforms to take to prevent this situation have not yet been selected in this case.
For the full list of how to protect your funds as a financial service, check our Prevention Policies for Platforms guide.
Regulatory Prevention Policies
No specific regulatory policies have yet been identified in this case.
For the full list of regulatory policies that can prevent loss, check our Prevention Policies for Regulators guide.
References
- ↑ TenArmor - "Our system has detected a suspicious sandwich attack involving #YB on #BSC, resulting in an approximately loss of $15.3K." - Twitter/X (Accessed Aug 6, 2025)
- ↑ Sandwich Attack Transaction - BSCScan (Accessed Aug 6, 2025)
- ↑ YB token hack analysis - by TK - Verichains (Accessed Aug 6, 2025)
- ↑ Week 16, 2025 - BlockThreat (Accessed Aug 6, 2025)
- ↑ Address Of The Attacker - BSCScan (Accessed Aug 6, 2025)
- ↑ Vulnerable Smart Contract - BSCScan (Accessed Aug 6, 2025)
- ↑ Vulnerable Smart contract Creation - BSCScan (Accessed Aug 6, 2025)