Description:
The TokenDivider contract can unintentionally lock ETH when users send more than the required amount to fulfill a buy order. The excess ETH remains in the contract and cannot be withdrawn, as no mechanism exists to handle or refund the surplus.
Impact:
High. This behavior can lead to user funds being irretrievably locked, which is not the expected functionality and can harm user trust and experience.
Proof of Concept:
Consider a scenario where a user sends 2 ETH to fulfill an order requiring only 1 ETH. The excess 1 ETH remains trapped in the contract.
Recommended Mitigation:
You have two options:
send back the surplus of eth
or require the user to send the exact amount of eth when fullfiling the buy order.
The extra eth sent by the user in the buy order will be locked in the contract forever
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.