recoverTokens places no restriction on which token address is passed. Aave aTokens (e.g. aUSDC, aWETH) are standard ERC20 tokens held by the contract representing deposited collateral. Transferring them out reduces the collateral backing active positions without going through unwindPosition, bypassing health factor checks and flash loan repayment logic.
Likelihood:
Becomes exploitable when the contract evolves to hold positions for multiple users, as indicated by the NFT TODO comment at Stratax.sol:158
A compromised owner key can drain all aToken collateral in a single transaction
Impact:
Collateral drained without triggering any health factor or unwind checks — positions become immediately undercollateralized
In the planned multi-user NFT model, one user's collateral can be stolen, causing other users' positions to be liquidated
Maintain a mapping of protected token addresses (Aave aTokens) that cannot be withdrawn via recoverTokens. The owner registers aToken addresses when positions are opened. This preserves the recovery function for genuinely stuck tokens (e.g. accidentally sent ERC20s) while preventing it from being used to drain active position collateral.
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.