The LikeRegistry::likeUser
function uses require(msg.value >= 1 ether)
, allowing users to overpay. Excess ETH
is neither refunded nor tracked.
According to the documentation, the protocol expects exactly 1 ETH
per like, but overpayments create accounting discrepancies.
Users can lose ETH by sending more than 1 ether. Protocol revenue calculations and reward distributions are inaccurate.
Simulates user sending 1.5 ETH
(instead of 1 ETH) to like user2
.
Checks the balance of the LikeRegistry contract.
The contract holds 1.5 ETH
, proving that overpayments are not refunded.
Add a refund mechanism or cap payment at exactly 1 ETH
Please read the CodeHawks documentation to know which submissions are valid. If you disagree, provide a coded PoC and explain the real likelihood and the detailed impact on the mainnet without any supposition (if, it could, etc) to prove your point.
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.