link.png

ID:

babyswap-1186

Date:

Status:

Incident Count:

October 1, 2022

Verified

1

info.png
target.png
REKT

Contributor:

chain.png

web3rekt.com

KYC By:

KYC:

None

info.png

Audit By:

Audits:

Certik

Loss Amount:

65,055

info.png

Recovered:

-

Rewards:

Ticker:

USD

info.png

Key Indicators

Platform:

Type:

Category:

Method:

Data Sources:

Binance Smart Chain

Protocol

Dexes

Contract Vulnerabilities

Extended Method:

Logic error with the takeWithdraw function

info.png

Days in Operation:

519

(1.42 Years)

chain.png
chain.png
chain.png
chain.png
datasource.png

BlockSec reported an analysis on Babyswap's recent vulnerability.

The root cause is that the "factory" parameter of the router can be faked. Thus a fake swap can earn the BABY rewards token.

From the trace, one can see that the factory is an attacker-controlled one. Then the swap in the router is controlled by the attacker. But for the swap mining contract, the factory is a real one, and the contract thinks there is a real swap and records rewards. Then the attacker claim rewards through takerWithdraw.

info.png

DISCLAIMER: While web3rekt has used the best efforts in aggregating and maintaining this database, this web site makes no representations or warranties with respect to the accuracy or completeness of its information and data herein, and specifically disclaim any implied warranties of merchantability or fitness for any particular purpose. 

Under no circumstances, shall web3rekt be liable for any loss of profit or funds, any regulatory or governmental penalties, any legal costs, or any other commercial and non-commercial damages, including but not limited to special, incidental, consequential, or other damages from any or all usage of the data and information derived from this database.