Closed c4-bot-1 closed 9 months ago
bytes032 marked the issue as insufficient quality report
QA
The Warden has specified how the configuration of the maximum Yang (collateral) deposit limit is not sanitized. As its configuration is an administrative action, this submission cannot constitute an HM vulnerability and would instead be considered QA (NC) as a nice-to-have validation.
alex-ppg changed the severity to QA (Quality Assurance)
alex-ppg marked the issue as grade-c
Lines of code
https://github.com/code-423n4/2024-01-opus/blob/main/src/core/sentinel.cairo#L223
Vulnerability details
Impact
The current implementation of sentinel, allows to set
sentinel.yang_asset_max
arbitrary value for the yang. But while adding a yang, initial deposit of 1000 will be made. Which technically means that the yang token value can never be below 1000. But this lower bound check has not been imposed in the current implementation ofset_yang_asset_max
function.Proof of Concept
Tools Used
Manual Review
Recommended Mitigation Steps
Assessed type
Invalid Validation