quantammAdmin not updated when new weight runner is setIn the constructor of the QuantAMMWeightedPool, the quantammAdmin is set by calling the quantammAdmin function of the set updateWeightRunner.
However, further down, there's the setUpdateWeightRunnerAddress which allows the quantammAdmin to set a new updateWeightRunner contract.
This, however, and coupled with the fact that the quantammAdmin parameter is marked as immutable, means that the quantammAdmin is not (and cannot) updated when a new updateWeightRunner is set.
The new updateWeightRunner's quantamm admin has no control over the QuantAMMWeightedPool. If the new updateWeightRunner is set due to emergency actions, the new admin is locked out, while the old admin can still make changes.
Change the imutability status of the quantammAdmin parameter and set the new quantammAdmin in the setUpdateWeightRunnerAddress function.
oracleStalenessThreshold parameterQuantAMMWeightedPool.sol's initialization allows setting the oracle staleness threshold.
Also, there's no function to update this parmaeter, hence the same staleness threshold is used for all oracle feeds being queried by the update weight runner.
This can lead to a number of issues when querying prices. For instance, if the price feed is one that is slow to update e.g (most LSTs/ETH feeds), after a certain point, their price become unqueriable because the currently set threshold will be too small for their last update time, if its one that updates very fast, stale prices may be allowed if the oracle for some reason fails to update. This issue is also excarcebated by the fact that the contrracts are to be deployed accross various chains where these thresholds may be different.
Use the ruleOracleStalenessThreshold mapping instead to set the staleness threshold for each oracle feed in use.
poolsFeeData restriction can be bypassed through transfersWhen a user adds liquidity, there's a restriction to ensure that the user doesn't have more than 100 poolFeeData attached to their address.
This restriction is however not placed in the afterUpdate hook, which is called during lpNFT transfers which also pushes a new poolsFeeData into the user's array.
This makes the restriction ineffective in the attempts to protect against DDoS attacks.
Enforce the restriction in the afterUpdate hook too.
Likelihood: Medium/High, anyone can receive an unlimited NFT number but will cost creation of LP tokens and sending them. Impact: Low/Medium, DoS the afterUpdate and addLiquidityProportional but will be mitigable on-chain because a lot of those NFT can be burn easily in onAfterRemoveLiquidity.
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.