Eggstravaganza

First Flight #37
Beginner FriendlySolidity
100 EXP
View results
Submission Details
Severity: high
Valid

User with No NFTs can withdraw one

Summary

a user with no NFTS can able to claim one

Vulnerability Details

if user A transfers NFT to the EggVault contract address , with the help of EggVault::depositEgg function user B can able to change the eggDepositors[tokenId] state to his contract address and can able to withdraw the NFT that was sent by user A

Impact - High

LikelyHood - Low

Tools Used

Manul Review

Recommendations

As EggVault::depositEgg was used by the EggHuntGame we need to add a condition that only the EggHuntGame contract can able to deposit

And if we thought of having a function that users can able to deposit to vault directly we can implement one

Updates

Lead Judging Commences

m3dython Lead Judge 5 months ago
Submission Judgement Published
Validated
Assigned finding tags:

Frontrunning Vulnerability DepositEgg

Front-running depositEgg allows deposit ownership hijacking.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.