Description
The Solidity base bridge contract (PolygonZkEVMBridgeV2.sol) inherits EmergencyManager, which provides a simple emergency state toggle controlled by the rollup manager (a trusted system contract). When emergency state is active, the ifNotEmergencyState modifier blocks all user-facing operations:
The emergency state is a simple boolean flag managed by a single trusted role.
The Miden bridge has no equivalent mechanism. All bridge operations (bridge_out, claim, register_faucet, update_ger) execute unconditionally with no pause flag check. There is no storage slot for an emergency state and no note type to toggle it.
Impact
If a vulnerability is discovered in the bridge logic, or a GER manager is compromised and inserts fraudulent GERs, there is no way to stop the bridge from processing transactions while the issue is investigated and fixed.
Recommended Action
Add an emergency_paused flag in bridge storage. All entry-point procedures (bridge_out, claim, register_faucet, update_ger) should check this flag at the start and panic if set. Add a bridge-admin-gated set_emergency_paused procedure to toggle the flag, along with a corresponding note script or CONFIG_AGG_BRIDGE extension to invoke it.
Dependencies
- Issue 001b extends this with separate pauser/unpauser roles
References
Classification
This is a core feature of the base bridge contract (PolygonZkEVMBridgeV2).
Description
The Solidity base bridge contract (
PolygonZkEVMBridgeV2.sol) inheritsEmergencyManager, which provides a simple emergency state toggle controlled by the rollup manager (a trusted system contract). When emergency state is active, theifNotEmergencyStatemodifier blocks all user-facing operations:activateEmergencyState()- gated byonlyRollupManagerdeactivateEmergencyState()- gated byonlyRollupManagerifNotEmergencyStatemodifier gates:bridgeAsset,claimAsset,bridgeMessage,claimMessageThe emergency state is a simple boolean flag managed by a single trusted role.
The Miden bridge has no equivalent mechanism. All bridge operations (
bridge_out,claim,register_faucet,update_ger) execute unconditionally with no pause flag check. There is no storage slot for an emergency state and no note type to toggle it.Impact
If a vulnerability is discovered in the bridge logic, or a GER manager is compromised and inserts fraudulent GERs, there is no way to stop the bridge from processing transactions while the issue is investigated and fixed.
Recommended Action
Add an
emergency_pausedflag in bridge storage. All entry-point procedures (bridge_out,claim,register_faucet,update_ger) should check this flag at the start and panic if set. Add a bridge-admin-gatedset_emergency_pausedprocedure to toggle the flag, along with a corresponding note script or CONFIG_AGG_BRIDGE extension to invoke it.Dependencies
References
bridge_out.masmbridge_in.masmbridge_config.masmbridge.rsPolygonZkEVMBridgeV2.solClassification
This is a core feature of the base bridge contract (
PolygonZkEVMBridgeV2).