Starknet Auction

First Flight #26
Beginner FriendlyNFT
100 EXP
View results
Submission Details
Severity: high
Valid

The Highest Bidder Can Withdraw Their Bid

Summary

Thie highst bidder is able to withdraw their bid after the auction has ended.

Vulnerability Details

After the highest bidder has won the auction they are able to withdraw their bid before the owner is able to collect the winnings.

Impact

This means that the highest bidder will have won the NFT and is still able to withdraw their winning bid from the smart contract essentially stealing the NFT.

Tools Used

Manual Review

Recommendations

Update line 131 to the following: : if amount > 0 && caller != self.highest_bidder.read()

Updates

Lead Judging Commences

bube Lead Judge 9 months ago
Submission Judgement Published
Validated
Assigned finding tags:

The `highest_bidder` can withdraw the value of all bids

The `withdraw` function allows the participants to receive back the value of all their unsuccessful bids. The problem is that the winner of the auction will receive all bids including the `highest_bid` that should be paid to the NFT owner.

Support

FAQs

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