A design inconsistency exists in the auction extension mechanism where first bids and subsequent bids use different logic to extend auction end times. First bids correctly extend from the current timestamp, while subsequent bids incorrectly extend from the original end time, resulting in unpredictable and unfair extension durations.
The placeBid function implements two different extension mechanisms:
For First Bids (no previous bid):
This correctly sets the auction to end 15 minutes from the current time.
For Subsequent Bids (with previous bid):
This adds 15 minutes to the original end time, not the current time.
Given: S_AUCTION_EXTENSION_DURATION = 15 minutes
First bid at 4:30 PM
Auction end set to: 4:45 PM (4:30 + 15 min) ✓ Correct
Second bid at 4:35 PM (10 minutes before original end)
Time left: 10 minutes
Since 10 < 15, extension triggers
New auction end: 5:00 PM (4:45 + 15 min)
Actual time given to bidder: 25 minutes (4:35 → 5:00)
Third bid at 4:55 PM (5 minutes before current end)
Time left: 5 minutes
Since 5 < 15, extension triggers
New auction end: 5:15 PM (5:00 + 15 min)
Actual time given to bidder: 20 minutes (4:55 → 5:15)
Unfair Advantage: Later bidders receive significantly more time than the intended 15-minute extension window
Inconsistent Behavior: First bid logic differs from subsequent bid logic, creating unpredictable auction behavior
Make the subsequent bid extension logic consistent with the first bid logic by extending from the current timestamp
BidBeast marketplace contains a flaw in its auction timing mechanism. This causes the contract to miscalculate the actual end time of an auction, resulting in auctions that either conclude prematurely or run longer than specified.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.