Skip to content

Files

29 lines (23 loc) · 1.03 KB

External Call Reverts if Period Has Not Elapsed.md

File metadata and controls

29 lines (23 loc) · 1.03 KB

The function notifyRewardAmount() will revert if block.timestamp >= periodFinish.

However this function is called indirectly via the Synthetix.mint() function.

A revert here would cause the external call to fail and thereby halt the mint process.

Synthetix.mint() cannot be successfully called until enough time has elapsed for the period to finish.

Recommendation:

Consider handling the case where the reward period has not elapsed without reverting the call.


Slide Screenshot

074.jpg


Slide Text

  • Sigma Prime Unipool Finding 3
  • Error Handling
  • High Severity
  • External Call Reverts -> Mint Blocked
  • Handle Condition Without Reverting

References


Tags