Normal behavior: The constructor should validate that each provided token address is non‐zero and unique, then initialize the core tokens (wETH, wBTC, wSOL, USDC) and owner correctly.
Issue: Originally, the constructor only checked for zero‐address inputs but did not prevent two or more of the token parameters from being the same address. This can lead to ambiguous order labeling and UI/log confusion.
Likelihood:
Reason 1: Deploy scripts with misconfigured environment variables can assign the same address to both _weth
and _wbtc
.
Reason 2: A malicious owner could intentionally alias wETH as wBTC to defraud buyers.
Impact:
Impact 1: Loss of Funds: A buyer sends USDC expecting to receive wBTC but instead gets wETH, causing financial loss or unexpected asset exposure.
Impact 2: Operational misinterpretation: Analytics or on-chain watchers could misclassify traded assets, undermining reporting accuracy.
Because we passed the same address for both _weth
and _wbtc
, the contract thought it was listing wBTC but was in fact holding the wETH token. When the buyer calls buyOrder(1)
, they see ‘Bought wBTC’ in the UI but actually get wETH—locking in a loss or at least an unwanted asset swap.
By rejecting deployments where any two of the token parameters are identical,
we guarantee that each order’s symbol and underlying contract always match.
That fail-fast behavior prevents a mis-labeled ‘wBTC’ order from actually routing wETH to buyers
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.