https://github.com/Cyfrin/2024-07-zaros/blob/main/src/perpetuals/branches/LiquidationBranch.sol#L105-L223
Lack of boundary checks in liquidateAccounts
can lead to unintended behavior by processing invalid or non-existent accounts.
The function does not verify if the account IDs in accountsIds
are valid or if the accounts exist. This oversight can lead to unintended behavior, such as processing invalid accounts or encountering errors during execution.
Unintended Behavior: Processing invalid or non-existent accounts can lead to errors or unexpected results.
Operational Issues: Lack of validation might cause the function to behave unpredictably.
Manual
Add Boundary Checks: Ensure that the account IDs are within valid bounds and that the accounts exist before processing.
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.