Submitted by HChang26, also found by immeas, sces60107, phoenixV110, Neon2835, tnquanghuy0512, c3phas, lsaudit, MrPotatoMagic, ayden, volodya, oakcobalt, Kow, DeFiHackLabs, t0x1c, xAriextz, ubl4nk, peanuts, oualidpro, 0x3b, 0xMAKEOUTHILL, merlin, 0xSwahili, innertia, mojito_auditor, 0xarno, Haipls, Eigenvectors, alexfilippov314, Nyx, ohm, Zac, and ABA
https://github.com/code-423n4/2023-10-nextgen/blob/main/smart-contracts/AuctionDemo.sol#L57
https://github.com/code-423n4/2023-10-nextgen/blob/main/smart-contracts/AuctionDemo.sol#L104
Bidder funds may become irretrievable if the participateToAuction() function is executed after claimAuction() during a 1-second overlap.
The protocol allows bidders to use the participateToAuction() function up to the auctions end time.
However, the issue arises when an auction winner immediately calls claimAuction() right after the auction concludes, creating a 1-second window during which both claimAuction() and participateToAuction() can be executed.
The issue arises when claimAuction() is executed before participateToAuction() within this 1-second overlap. In such a scenario, the bidders funds will become trapped in AuctionDemo.sol without any mechanism to facilitate refunds. Both cancelBid() and cancelAllBids() functions will revert after the auctions conclusion, making it impossible for bidders to recover their funds.
Context
a2rocket (NextGen) confirmed via duplicate issue #962
0xsomeone (judge) commented:
Note: For full discussion, see here.
