VYPR
Critical severityNVD Advisory· Published Aug 26, 2021· Updated Aug 4, 2024

TimelockController vulnerability in OpenZeppelin Contracts

CVE-2021-39168

Description

OpenZepplin is a library for smart contract development. In affected versions a vulnerability in TimelockController allowed an actor with the executor role to escalate privileges. Further details about the vulnerability will be disclosed at a later date. As a workaround revoke the executor role from accounts not strictly under the team's control. We recommend revoking all executors that are not also proposers. When applying this mitigation, ensure there is at least one proposer and executor remaining.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

A vulnerability in OpenZeppelin's TimelockController allows an executor to escalate privileges and take control of the timelock.

Vulnerability

In OpenZeppelin Contracts versions before 4.3.1 and 3.4.2, the TimelockController contract contains a privilege escalation vulnerability. The _beforeCall function did not verify that the operation was ready before execution, allowing an actor with the EXECUTOR_ROLE to bypass the timelock delay and execute operations prematurely. This affects all deployments using the affected versions. [2][4]

Exploitation

An attacker with the EXECUTOR_ROLE can call execute or executeBatch with an operation that has not yet become ready (i.e., before the timelock delay has elapsed). The missing isOperationReady check in _beforeCall allows the operation to be executed immediately. If the executor role is set to "open" (anyone can assume it), any user can exploit this. [3][4]

Impact

Successful exploitation allows the attacker to reset the timelock delay to zero and escalate privileges, effectively taking full control of the timelock contract. This grants unrestricted access to all assets held in the contract, including tokens and ownership rights. [4]

Mitigation

The fix is included in versions 4.3.1, 3.4.2, and 3.4.2-solc-0.7 of @openzeppelin/contracts and @openzeppelin/contracts-upgradeable. Deployed instances should be replaced with a fixed version by migrating all assets, ownership, and roles. As a workaround, revoke the executor role from accounts not strictly under the team's control, ensuring at least one proposer and executor remain. [2][4]

AI Insight generated on May 21, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
@openzeppelin/contracts-upgradeablenpm
>= 4.0.0, < 4.3.14.3.1
@openzeppelin/contracts-upgradeablenpm
>= 3.3.0, < 3.4.23.4.2

Affected products

2

Patches

0

No patches discovered yet.

Vulnerability mechanics

AI mechanics synthesis has not run for this CVE yet.

References

5

News mentions

0

No linked articles in our index yet.