Closed code423n4 closed 1 year ago
Technically all LooksRare listings have WETH as the currency. We will be forcing the users in the frontend to provide ETH instead of WETH if it’s a LooksRare order.
0xhiroshi marked the issue as sponsor disputed
Downgrading to QA, see https://github.com/code-423n4/2022-11-looksrare-findings/issues/72
Lines of code
https://github.com/code-423n4/2022-11-looksrare/blob/main/contracts/proxies/LooksRareProxy.sol#L115-#L132
Vulnerability details
Impact
User cannot buy NFT with ERC20 tokens with LooksRareProxy even with WETH.
Proof of Concept
This is the current implementation of
matchAskWithTakerBidUsingETHAndWETH
, this function only takesETH
orWETH
as payment:So although LooksRareProxy allows you to specify
order.currency
any ERC20 token, it will eventually fail with errorOrder: Currency must be WETH
. Even if user useWETH
, either the transaction will fail orWETH
is ignored, sinceLooksRareProxy.sol
will always transfervalue=takerBid.price
toLooksRareExchange
:Due to this code:
LooksRareExchange
will only takeWETH
iftakerBid.price > msg.value
; however, sinceLooksRareProxy
always transfervalue=takerBid.price
, this will never happen.Tools Used
Manual code review
Recommended Mitigation Steps
I recommend only transfer the amount of ETH that user send to aggregator.