The quantAMMSwapFeeTake
variable is used for both swap fee and uplift fee.
This creates ambiguity in the contract's logic and exposes the system to potential misconfiguration or misuse, both setQuantAMMSwapFeeTake
and setQuantAMMUpliftFeeTake
methods modify the same state variable quantAMMSwapFeeTake
, and both getQuantAMMSwapFeeTake
and getQuantAMMUpliftFeeTake
returns its value.
Both swap fee QuantAMMSwapFeeTake
and uplift fee QuantAMMUpliftFeeTake
share the same state variable, quantAMMSwapFeeTake
.
Modifying one fee setting overwrites the value for the other, causing potential fee loss if Admin decided to update swap fee the uplift fee
will also updated.
POC: add test in UpdateWeightRunner.t.sol
Result:
If fees are misconfigured, the protocol might either overcharge or undercharge users, leading to a loss of fee revenue for Admin.
Likelyhood: High, calling setters or getters Impact: Low/Medium, both getters return `quantAMMSwapFeeTake` and `setQuantAMMUpliftFeeTake` modify `quantAMMUplfitFeeTake`. Real impact: those 2 values will be always the same.
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.