The Game contract updatePlatformFeePercentage function allows the owner to set platformFeePercentage to any value between 0 and 100 via the isValidPercentage modifier. Setting platformFeePercentage to 0 results in no platform fees being collected in claimThrone, causing all sentAmount to go to the pot, which can disrupt the game’s economic balance.
Likelihood:
Owner can set platformFeePercentage = 0 intentionally or by mistake, as the modifier allows it.
Common during testing or misconfiguration, especially if the owner underestimates the impact.
No platform fees are collected, reducing owner incentives and potentially starving contract operations.
Before running this test, Kindly change the clamThrone require to
require(msg.sender != currentKing);
Tool Used
Manual Review
Code Snippet
Consider addng this line of code in isValidPercentage modifier
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.