The Treasury::deposit and Treasury::withdraw functions directly use the parameter amount to update _balances without verifying actual balance changes. This creates discrepancies when handling non-standard tokens where transferred amounts may differ from the parameter value. For example, when passing type(uint256).max as amount, a token contract might transfer its actual balance while _balances gets erroneously recorded as type(uint256).max, potentially blocking subsequent withdrawals from manage roles.
Balance Record Manipulation: Non-standard tokens can corrupt _balances tracking
Withdrawal Functionality Failure: Manager role unable to withdraw actual balances
Accounting System Compromise: Financial records become untrustworthy
Manual Review
Update _banlance by calculating actual balance changes rather than trusting the amount parameter
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.