Description: The AMM doesn't validate or handle non-standard token behaviors like fee-on-transfer tokens or rebasing tokens. The AMM assumes all tokens follow standard SPL token behavior. However, some tokens implement custom behaviors like taking fees on transfers or rebasing (changing total supply). The AMM doesn't validate actual amounts received after transfers, which could lead to accounting inconsistencies.
Impact:
Pools with fee-on-transfer tokens would have incorrect accounting
Rebasing tokens could cause unexpected behavior in pools
Potential for economic exploits using non-standard tokens
Proof of Concept: With a fee-on-transfer token:
Recommended Mitigation: Implement balance checking before and after transfers to validate actual amounts received in the liquidity_operations::provide_liquidity
function:
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.