QuantAMM

QuantAMM
49,600 OP
View results
Submission Details
Severity: medium
Valid

The `quantAMMUpliftFee` Variable Is Missing

Summary

In the setQuantAMMUpliftFeeTake function, the quantAMMSwapFeeTake variable is updated, and the getQuantAMMUpliftFeeTake function returns the value of quantAMMSwapFeeTake. However, there is no dedicated quantAMMUpliftFee variable, leading to potential overwriting and overreading of quantAMMSwapFeeTake. This causes the protocol to deviate from the intended behavior set by the admin.

Vulnerability Details

The absence of a quantAMMUpliftFee variable results in the incorrect use of quantAMMSwapFeeTake for uplift fee operations. This overlap leads to unintended behavior, preventing the protocol from functioning as designed.

Impact

The protocol fails to collect uplift fees as intended, potentially reducing revenue and causing operational inconsistencies.

Tools Used

Manual Review

Recommendations

Introduce a dedicated quantAMMUpliftFee variable

Updates

Lead Judging Commences

n0kto Lead Judge 7 months ago
Submission Judgement Published
Validated
Assigned finding tags:

finding_quantAMMSwapFeeTake==quantAMMUplfitFeeTake

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.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.