Normal behavior: Aave flash loans provide _premium in the executeOperation callback, which must be repaid along with the borrowed amount. The protocol can change this fee dynamically.
Issue: Stratax hardcodes the flash loan fee as flashLoanFeeBps = 9 (0.09%) in initialize(). Internal functions like _executeOpenOperation and _executeUnwindOperation calculate repayment using this fixed fee instead of the _premium parameter.
Likelihood:
If Aave updates the flash loan fee (e.g., from 0.09% → 0.1%), the contract underestimates repayment.
Any flash loan operation (createLeveragedPosition or unwindPosition) will revert, blocking users.
Impact:
Denial of Service (DoS): Users cannot open or unwind positions until the contract is upgraded.
Positions cannot be fully managed; user funds can effectively be locked.
The contract uses a static fee to compute repayment amounts. If the real Aave flash loan premium increases, the contract cannot repay the loan, causing any flash loan operation to fail. This results in permanent DoS for position creation/unwinding until the contract logic is fixed.
Always use \_premium provided by Aave in executeOperation.
Remove dependency on flashLoanFeeBps for repayment calculations.
Optionally, keep flashLoanFeeBps for informational purposes, but never for repayment logic.
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.
The contest is complete and the rewards are being distributed.