XDEFI contest - Fitraldys's results

The fastest wallet in DeFi.

General Information

Platform: Code4rena

Start Date: 04/01/2022

Pot Size: $25,000 USDC

Total HM: 3

Participants: 40

Period: 3 days

Judge: Ivo Georgiev

Total Solo HM: 1

Id: 75

League: ETH

XDEFI

Findings Distribution

Researcher Performance

Rank: 6/40

Findings: 2

Award: $869.20

🌟 Selected for report: 1

🚀 Solo Findings: 0

Findings Information

🌟 Selected for report: cccz

Also found by: Fitraldys, cmichel, kenzo, onewayfunction, tqts

Labels

bug
duplicate
3 (High Risk)
sponsor confirmed

Awards

768.967 USDC - $768.97

External Links

Handle

Fitraldys

Vulnerability details

Impact

A user can call lock() that will call _lock(), that eventually will call _safeMint(), the _safeMint() function will make an external call to the destination address through _checkOnERC721Received(), and since the merge() and updateDistribution() didnt have noreentrant modifier, the user can reenter one of this function.

note: the _lock() didnt follow the correct check effect pattern, because external call from _safeMint() is happening before the state change

Proof of Concept

  • XDEFIDistribution.sol -> updateDistribution()
  • XDEFIDistribution.sol -> merge()
  • XDEFIDistribution.sol -> _lock()

#0 - deluca-mike

2022-01-09T05:56:47Z

Valid, and duplicate of #25

AuditHub

A portfolio for auditors, a security profile for protocols, a hub for web3 security.

Built bymalatrax © 2024

Auditors

Browse

Contests

Browse

Get in touch

ContactTwitter