Skip to content

acl

Access control operations: Ownable ownership, AccessControl and AccessManager roles.

load acl
CommandDescription
acl:accept-default-admin-transferAccept a pending default admin transfer after its schedule has passed. Must be sent by the pending admin.
acl:accept-ownershipAccept a pending ownership transfer of an Ownable2Step contract. Must be sent by the pending owner.
acl:begin-default-admin-transferStart the delayed two-step transfer of the DEFAULT_ADMIN_ROLE on an AccessControlDefaultAdminRules contract.
acl:cancel-default-admin-transferCancel a pending default admin transfer. Must be sent by the current default admin.
acl:cancel-scheduledCancel a scheduled AccessManager operation. Callable by its scheduler, a guardian of the required role, or an admin.
acl:change-default-admin-delaySchedule a change of the delay applied to future default admin transfers.
acl:execute-scheduledExecute an operation through an AccessManager, consuming its schedule when the operation was delayed.
acl:grantGrant a role on an AccessControl contract (string roles, hashed with keccak256) or an AccessManager (numeric role ids).
acl:label-roleAttach a human-readable label to an AccessManager role (emitted as an event for off-chain indexing).
acl:renounceRenounce a role held by the connected account on an AccessControl contract or an AccessManager.
acl:renounce-ownershipRenounce ownership of an Ownable contract, leaving it without an owner and permanently disabling its onlyOwner functions.
acl:revokeRevoke a role on an AccessControl contract (string roles, hashed with keccak256) or an AccessManager (numeric role ids).
acl:rollback-default-admin-delayCancel a scheduled default admin delay change.
acl:scheduleSchedule a delayed operation on an AccessManager for later execution with acl:execute-scheduled.
acl:set-role-adminSet the admin role that manages grants and revocations of an AccessManager role.
acl:set-role-guardianSet the guardian role allowed to cancel scheduled operations of an AccessManager role.
acl:set-target-closedClose or reopen a contract managed by an AccessManager. While closed, all calls to its restricted functions revert.
acl:set-target-function-roleMap functions of a managed contract to the AccessManager role required to call them.
acl:transfer-ownershipTransfer ownership of an Ownable contract. On Ownable2Step contracts this stages the pending owner, who must then accept.
HelperReturnsDescription
@acl:canCallboolWhether a caller can immediately call a restricted function of a contract managed by an AccessManager.
@acl:defaultAdminaddressCurrent default admin of an AccessControlDefaultAdminRules contract.
@acl:defaultAdminDelaynumberDelay in seconds applied to default admin transfers of an AccessControlDefaultAdminRules contract.
@acl:hasRoleboolWhether an account holds a role on an AccessControl contract (string roles) or an AccessManager (numeric role ids).
@acl:operationIdbytes32Operation id of an AccessManager call (hashOperation of caller, target and calldata), for use with @acl:operationSchedule.
@acl:operationSchedulenumberTimestamp at which a scheduled AccessManager operation becomes executable (0 when unset, expired or already executed).
@acl:owneraddressCurrent owner of an Ownable contract.
@acl:pendingDefaultAdminaddressPending default admin of an AccessControlDefaultAdminRules contract (the zero address when no transfer is in progress).
@acl:pendingOwneraddressPending owner of an Ownable2Step contract (the zero address when no transfer is in progress).
@acl:roleAdminbytes32 | numberAdmin role that controls a role: a bytes32 value on AccessControl contracts, a role id on AccessManagers.