Description: The LikeRegistry::likeUser
function fails to update user balances when users send ETH to like other users.
The missing balance update means that even though users send ETH to the contract, their balances are never recorded. This breaks two core features:
Match rewards cannot be distributed because user balances remain at 0
Protocol fees are never collected since they're based on user balances
Impact:
All ETH sent by users becomes permanently stuck in the contract
Match rewards system is completely broken
Protocol fee collection mechanism fails
Users lose funds without receiving intended benefits
Proof of Concept:
Alice sends 1 ETH to like Bob
Bob sends 1 ETH to like Alice back
They match, but no rewards are distributed because their balances were never recorded
The contract now holds 2 ETH that can't be distributed
Proof of Code:
Add this test to your test file (it would be better to create a new test file LikeRegistry.t.sol
)
Recommended Mitigation: Update userBalances when calling LikeRegistry::likeUser
function.
Likelihood: High, always. Impact: High, loss of funds
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.