transferFrom Return Value Not Checked When Pulling Collateral
Description:
Stratax::createLeveragedPosition pulls user collateral using IERC20.transferFrom but does not verify the transfer succeeded:
Some ERC20 tokens return false on failure instead of reverting. Ignoring the return value can cause the function to continue execution even if the transfer failed (or appear to fail in non-standard ways), leading to unexpected behavior when later steps assume collateral was received.
Impact:
Medium. If collateral is not actually transferred in, subsequent protocol actions may revert later (harder to diagnose) or operate under invalid assumptions, breaking the open-position flow and potentially causing funds/operations to get stuck mid-transaction (depending on downstream calls).
Recommended Mitigation:
At minimum, check the returned boolean (note: this does not cover tokens that do not return a bool):
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.