yy
medium
There is no max supply cap for token in this contract.
The function mintForToken
does not have access control, everyone such as Alice can use the function keep mint an excessive amount of coins, then leading to inflation and devaluation of the token. Even the calculateMint
function provide a limit on how much tokens can be minted per transaction.
However, it does not prevent inflation or devaluation from excessive minting, especially if the user has a large amount of asset token.
No prevention for inflation or devaluation from excessive minting, especially if the user has an enormous amount of asset token.
https://github.com/sherlock-audit/2023-05-USSD/blob/main/ussd-contracts/contracts/USSD.sol#L151 https://github.com/sherlock-audit/2023-05-USSD/blob/main/ussd-contracts/contracts/USSD.sol#LL169C5-L174C1
Manual Review
Rate limiting or maximum supply cap for the stablecoin could be considered to protect the stablecoin's value.