# Safety Module States

The Safety Module can be in three states:

```solidity
enum SafetyModuleState {
  ACTIVE,
  TRIGGERED,
  PAUSED
}
```

The table below details valid state transitions:

| From      | To        | Notes                                                                                                                                                                                                                                          |
| --------- | --------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| ACTIVE    | TRIGGERED | <p>Occurs when <code>SafetyModule.trigger(</code></p><p><code>triggerEventId\_)</code> is executed with a valid controller and the SafetyModule is not <code>PAUSED</code> (see <a href="safety-module-raises">Safety Module Raising</a>).</p> |
| ACTIVE    | PAUSED    | Occurs when either the protocol owner or pauser or the SafetyModule owner or pauser pauses the SafetyModule.                                                                                                                                   |
| TRIGGERED | ACTIVE    | Occurs when safety module has finished paying out all pending raises (see [Safety Module Raising](https://csm-docs.cozy.finance/developer-guides/safety-module-raises)).                                                                       |
| TRIGGERED | PAUSED    | Occurs when either the protocol pauser or SafetyModule pauser pauses the SafetyModule.                                                                                                                                                         |
| PAUSED    | ACTIVE    | Occurs when either the protocol owner or the SafetyModule owner unpauses the SafetyModule.                                                                                                                                                     |
| PAUSED    | TRIGGERED | Occurs when either the protocol owner or the SafetyModule owner unpauses the SafetyModule and `SafetyModule.numPendingRaises > 0` (see [Safety Module Raising](https://csm-docs.cozy.finance/developer-guides/safety-module-raises)).          |

\
The table below details which actions are allowed in each of these states:

<table><thead><tr><th width="230">Action / State</th><th>Active</th><th>Triggered</th><th>Paused</th></tr></thead><tbody><tr><td><strong>Deposit Reserve Assets</strong></td><td>Y</td><td>Y</td><td>N</td></tr><tr><td><strong>Queue Redeem Reserve Assets</strong></td><td>Y</td><td>N</td><td>N</td></tr><tr><td><strong>Complete Redeem Reserve Assets</strong></td><td>Y</td><td>N</td><td>N</td></tr><tr><td><strong>Instant Redeem Reserve Assets</strong></td><td>N</td><td>N</td><td>Y</td></tr><tr><td><strong>Trigger</strong></td><td>Y</td><td>Y</td><td>Y</td></tr><tr><td><strong>RequestRaise</strong></td><td>N</td><td>Y</td><td>N</td></tr><tr><td><strong>Queue Update Configs</strong></td><td>Y</td><td>N</td><td>Y</td></tr><tr><td><strong>Finalize</strong> <strong>Update Configs</strong></td><td>Y</td><td>N</td><td>Y</td></tr><tr><td><strong>Pause</strong></td><td>Y</td><td>Y</td><td>N</td></tr><tr><td><strong>Unpause</strong></td><td>N</td><td>N</td><td>Y</td></tr><tr><td><strong>Fees Drip</strong></td><td>Y</td><td>N</td><td>N</td></tr><tr><td><strong>Claim Fees</strong></td><td>Y</td><td>Y</td><td>Y</td></tr></tbody></table>
