Several setter functions in the StabilityPool contract lack checks to ensure that the provided addresses are non-zero. This oversight may result in the zero address being registered for critical roles, such as a manager, RAACMinter, or Liquidity Pool. Registering an invalid (zero) address can lead to misallocation of funds, unexpected behavior during contract interactions, and operational disruptions. Although this issue primarily affects efficiency and correctness rather than posing a direct security risk, it is classified as a low-severity issue.
addManager Function:
Issue: The function does not check whether manager is the zero address.
setRAACMinter Function:
Issue: The function lacks a check to ensure _raacMinter is non-zero.
setLiquidityPool Function:
Issue: This function also does not verify that _liquidityPool is a non-zero address before setting it.
Correctness Issues:
Allowing the zero address to be used in critical settings can lead to errors in fund allocation and may disrupt administrative functions.
Operational Disruption:
Subsequent operations that depend on these addresses (e.g., manager actions, RAACMinter functions, liquidity pool interactions) could fail or behave unpredictably if they reference an invalid address.
Severity:
This is a low-severity issue because it does not directly compromise funds or critical operations but affects the overall correctness and efficiency of the protocol.
Manual Review
Foundry
For each affected function, add a check to ensure that the provided address is not the zero address. Example modifications:
addManager Function:
setRAACMinter Function:
setLiquidityPool Function:
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.