Description: The refund()
function in the ChristmasDinner contract sends ETH to users without performing proper address validation checks. This is particularly concerning in the internal _refundETH
function that's called by refund()
. The actual vulnerability will be found here in the contract:
Impact:
Potential Loss of Funds:
If msg.sender
is a contract address that can't handle ETH (no receive/fallback function)
If msg.sender
is an invalid or incorrectly formatted address
If the address is self-destructed between balance check and transfer
Failed Transactions:
Transfer to invalid addresses will cause the entire transaction to revert
This could block legitimate refund attempts
Smart Contract Integration Issues:
Contracts interacting with this function might fail unexpectedly
No way to handle failed transfers gracefully
Proof of Concept:
Recommended Mitigation:
Add Address Validation:
Implement Safe Transfer Pattern:
Add Try-Catch Pattern:
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.