Attacker can delay proposal rejection
The rejectProposal function reverts if the proposed listing's collateral is less than the amount being rejected. An attacker can front-run a rejection transaction by reducing the collateral to one unit less than the amount, causing the rejection to fail and delaying it until the proposal period ends.
Submitted by gzeon
In OptimisticListingSeaport.rejectProposal, it reverts if proposedListing.collateral < _amount. An attacker can therefore monitor the mempool, reducing the proposedListing.collateral to _amount - 1 by frontrunning the rejectProposal call and delaying the rejection. The attacker may even be able to deny the rejection when the deadline passes.
if (proposedListing.collateral < _amount) revert InsufficientCollateral();
proposedListing.collateral -= _amount;
Proof of Concept
- Attacker proposes a 10000 collateral at a very low price
- Bob tries to reject it by purchasing the 10000 collateral
- Attacker sees Bob’s tx in the mempool, frontruns it to reject 1 unit
- The proposedListing.collateral is now 9999
- Bob’s call reverted
- This keeps happening until PROPOSAL_PERIOD passes or Bob gave up because of gas paid on failing tx
- Attacker buys the NFT at a very low price
Recommended Mitigation Steps
When proposedListing.collateral < _amount, set \_amount to proposedListing.collateral and refund the excess.
stevennevins (Tessera) disagreed with severity and commented:
While annoying, I think this is a Medium severity issue. The attacker has to under price their proposal, defend this under priced proposal from other users and front run each purchase > 1, while selling their Raes at a loss, and it would be relatively costly for griefer to defend their underpriced proposal for the duration of the proposal period. Users could purchase 1 Rae at a time without risk of front running.
HickupHH3 (judge) decreased severity to Medium and commented:
Agree with Medium severity given the external requirements needed to pull this off.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The rejectProposal function requires the collateral to be at least the amount being rejected, but an attacker can reduce the collateral by a small amount just before the rejection, causing it to revert.
Impact
The attacker can delay or prevent the rejection of an underpriced proposal, potentially buying the NFT at a very low price, though the attack requires external conditions and may be costly.
What the attacker needed
Attacker can propose a listing; attacker can front-run transactions; victim attempts to reject
The fix
When the collateral is less than the amount, set the amount to the collateral and refund the excess.
How it was found
- Attacker proposes a 10000 collateral at a very low price
- Bob tries to reject it by purchasing the 10000 collateral
- Attacker sees Bob’s tx in the mempool, frontruns it to reject 1 unit
- The proposedListing.collateral is now 9999
- Bob’s call reverted
- This keeps happening until PROPOSAL_PERIOD passes or Bob gave up because of gas paid on failing tx
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
When someone tries to reject a bad proposal by buying back the collateral, the attacker quickly makes a small change so the rejection fails. This is like someone constantly moving a finish line just before you cross it, so you can never complete the rejection.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.