Tadle allows user to set referrers via SystemConfig::updateReferrerInfo
. In that way referrers are able to earn percentage of platformFee
during PreMarkets::createTaker
function.
The issue is that because of a mistake in SystemConfig::updateReferrerInfo
code, it is only possible to refer the referrer himself.
SystemConfig::updateReferrerInfo
function sets referrer/referee info as follows:
Note that _referrer
is set as key in the mapping and as referralInfo.referrer
value -> This means that referrer will refer himself all the time.
Furthermore, the referralInfo
is used in SystemConfig::createTaker
function to payout the referrer a percentage of the platform fee. PreMarkets::_updateReferralBonus
function is responsible for managing the referral fee. Because of the issue inside SystemConfig::updateReferrerInfo
, this is the place where user will get the discount on the protocol fees.
User will get a discount on platform fees and referral system won't work as intended.
Manual Review
Inside the SystemConfig::updateReferrerInfo
do the following changes:
This ensures that referrer cannot refer the same address and referral system will work as intended
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.