The updateMarket
function in the smart contract SystemConfig
allows the owner to update critical market parameters, including token address, token per point, TGE (Token Generation Event), and settlement period. However, the function is vulnerable due to the lack of checks ensuring that the settlement period has passed before updating the market. This discrepancy between the function's implementation and its NatSpec documentation creates a significant security risk.
The updateMarket
function is intended to allow updates to market parameters only after the settlement period has passed. However, there is no check in the function to ensure that this condition is met. This oversight allows the owner to update market parameters at any time, even before the settlement period has concluded.
The owner could prematurely update the market parameters, including the token address and token-per-point ratio, potentially manipulating the market to their advantage or simply breaking the protocol. This could result in significant financial losses for participants relying on the integrity of the settlement period. Investors expect that the market will only be updated after the agreed-upon settlement period, and having a function that can break the protocol could cause dispute and make people lose trust in the protocol.
Manual Review
The following issues and its duplicates are invalid as admin errors/input validation/malicious intents are1 generally considered invalid based on [codehawks guidelines](https://docs.codehawks.com/hawks-auditors/how-to-determine-a-finding-validity#findings-that-may-be-invalid). If they deploy/set inputs of the contracts appropriately, there will be no issue. Additionally admins are trusted as noted in READ.ME they can break certain assumption of the code based on their actions, and
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.