The updateReferrerInfo
function is intended to update the referral information within the system when a user adds a new referral. However, a critical issue has been identified: although the function executes without any errors, it fails to actually update the referral information. As a result, the referral data remains unchanged.
The updateReferrerInfo
function is supposed to update the referral information when a user adds a referral. However, despite the function being called successfully and without any errors, the referral information is not updated in the system. This indicates a logical flaw within the function, where the expected update operation is not being performed. In the referralInfoMap, the referred user was passed instead of the user calling the updateReferrerInfo
function.
Add import "../src/interfaces/ISystemConfig.sol" to test/PreMarkets.t.sol
Run test in test/PreMarkets.t.sol
The primary impact of this issue is that the referral system fails to reflect new or updated referral information. This can result in users not receiving the appropriate benefits or rewards associated with their referrals
Manual Review
Update the correct user in the referralInfoMap mapping
Valid high severity. There are two impacts here due to the wrong setting of the `refferalInfoMap` mapping. 1. Wrong refferal info is always set, so the refferal will always be delegated to the refferer address instead of the caller 2. Anybody can arbitrarily change the referrer and referrer rate of any user, resulting in gaming of the refferal system I prefer #1500 description the most, be cause it seems to be the only issue although without a poc to fully describe all of the possible impacts
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.