Core Contracts

Regnum Aurum Acquisition Corp
HardhatReal World AssetsNFT
77,280 USDC
View results
Submission Details
Severity: low
Valid

EMERGENCY_DELAY is not forced when executes an emergency action in TimelockController

Summary

EMERGENCY_DELAY is not forced when executes an emergency action in TimelockController.

Vulnerability Details

In TimelockController, EMERGENCY_DELAY is defined to set a delay for emergency actions.

TimelockController.sol#L41-L42

/// @notice Delay for emergency actions (1 day)
uint256 public constant EMERGENCY_DELAY = 1 days;

However, when an emergency action is actually executed in executeEmergencyAction(), the emegency delay is not force.

TimelockController::executeEmergencyAction()

function executeEmergencyAction(
address[] calldata targets,
uint256[] calldata values,
bytes[] calldata calldatas,
bytes32 predecessor,
bytes32 salt
) external payable onlyRole(EMERGENCY_ROLE) nonReentrant {
bytes32 id = hashOperationBatch(targets, values, calldatas, predecessor, salt);
if (!_emergencyActions[id]) revert EmergencyActionNotScheduled(id);
delete _emergencyActions[id];
for (uint256 i = 0; i < targets.length; i++) {
(bool success, bytes memory returndata) = targets[i].call{value: values[i]}(calldatas[i]);
if (!success) {
if (returndata.length > 0) {
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
}
revert CallReverted(id, i);
}
}
emit EmergencyActionExecuted(id);
}

Impact

emegency delay is not forced when executes an emergency action as expected.

Tools Used

Manaual Review

Recommendations

Force emegency delay when executes an emergency action.

Updates

Lead Judging Commences

inallhonesty Lead Judge 3 months ago
Submission Judgement Published
Validated
Assigned finding tags:

TimelockController emergency actions bypass timelock by not enforcing EMERGENCY_DELAY, allowing immediate execution

inallhonesty Lead Judge 3 months ago
Submission Judgement Published
Validated
Assigned finding tags:

TimelockController emergency actions bypass timelock by not enforcing EMERGENCY_DELAY, allowing immediate execution

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.