Eggstravaganza

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

Lack of Reentrancy Protection

Summary

Location: EggHuntGame.sol, depositEggToVault() function

Vulnerability Details

The function performs an external call (NFT transfer) before updating state

eggNFT.transferFrom(msg.sender, address(eggVault), tokenId);
eggVault.depositEgg(tokenId, msg.sender);

Impact

  • Potential reentrancy attack if EggVault has callback functionality

  • Could allow malicious vault to reenter and manipulate game state

Tools Used

manual review

Recommendations

  • Implement checks-effects-interactions pattern

  • Add reentrancy guard (OpenZeppelin's ReentrancyGuard)

Updates

Lead Judging Commences

m3dython Lead Judge 4 months ago
Submission Judgement Published
Invalidated
Reason: Too generic

Support

FAQs

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