Buyer Listing DoS Through Zero-Price Asset Spam
A vulnerability has been identified in the Swan smart contract where malicious actors can prevent legitimate sellers from listing assets for a specific buyer by flooding the system with zero-price listings up to the maximum asset count limit.
In Swan.sol:168
, the contract validates that a seller cannot add a listing if the maxAssetCount
for that particular buyer has been reached, which it's shared between all asset sellers, but it fails to properly validate listing conditions, allowing an attacker to exploit the listing system. The relevant code section checks the asset count limit:
The vulnerability exists because:
There is no minimum price requirement for listings
Listings with zero price don't incur fees
The system only enforces a maximum asset count per buyer per round
No limit exists on how many zero-price assets a single seller can list
An attacker can:
Create multiple listings priced at 0 for a target buyer
Fill up the entire maxAssetCount
quota for that buyer's round
Effectively block legitimate sellers from listing assets
The impact of this vulnerability is severe:
Legitimate sellers are prevented from listing assets
Buyers cannot receive legitimate listings due to spam
Market functionality is compromised for targeted buyers
Potential for market manipulation and unfair competition
Manual Review
To address this vulnerability, consider implementing the following measures:
Minimum Price Requirements
Implement a minimum price threshold for listings
Ensure the minimum price covers at least the platform fees
Seller Listing Limits
Add per-seller limits for each buyer's round
Listing Fees
Require a listing fee regardless of asset price
This creates an economic disincentive for spam listings
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.