sherlock-audit / 2024-01-looksrare-judging

3 stars 0 forks source link

mgf15 - UNISWAP_V3_FACTORY vault hardcoded swap router address #122

Closed sherlock-admin2 closed 9 months ago

sherlock-admin2 commented 9 months ago

mgf15

medium

UNISWAP_V3_FACTORY vault hardcoded swap router address

Summary

According to scoping On what chains are the smart contracts going to be deployed? Mainnet Arbitrum Base Potentially any EVM compatible L2 (Including ZK L2s)

Vulnerability Detail

The address 0x1F98431c8aD98523631AE4a59f267346ea31F984 is different , on Base which is 0x33128a8fc17869897dce68ed026d694621f6fdfd which will lead to revert when called from the vault contract (empty return value).

Impact

will lead to revert when called from the vault contract (empty return value).

Code Snippet

https://github.com/sherlock-audit/2024-01-looksrare/blob/main/contracts-yolo/contracts/PriceOracle.sol#L19C27-L19C69

Tool used

Manual Review

Recommendation

Set the swap router address in constructor.

Duplicate of #42