Auction.sol#settleAuction()
addBounty with a fake token could potentially disrupt settleAuction()
#82
Labels
1 (Low Risk)
Assets are not at risk. State handling, function incorrect as to spec, issues with comments
bug
Warden finding
Handle
WatchPug
Vulnerability details
https://github.com/code-423n4/2021-09-defiProtocol/blob/main/contracts/contracts/Auction.sol#L102
Anyone can call
addBounty()
to add a bounty with any token. If we assume that the frontend will always pass all thebountyIDs
of active bounties tosettleAuction()
, then a malicious user can disruptsettleAuction()
byaddBounty
with a fake token that always reverts when callingtransfer()
.Impact
Auction bonder wont be able to
settleAuction()
. The malicious user and all other holders of the basket token can belifits from the burn of the auction bond.Proof of Concept
transfer()
;addBounty
with the fake token and any amount;settleAuction
withbountyIDs
including the fake token bounty will always fail.Recommended Mitigation Steps
Whitelist bounty tokens in smart contract or frontend.
The text was updated successfully, but these errors were encountered: