acl:revoke
Revoke a role on an AccessControl contract (string roles, hashed with keccak256) or an AccessManager (numeric role ids).
Syntax
Section titled “Syntax”acl:revoke <role> <on> <target> <from> <account>Arguments
Section titled “Arguments”| Name | Type | Description |
|---|---|---|
role | number | string | Role name (e.g. MINTER_ROLE), bytes32 value, or AccessManager role id |
on | command | Keyword on |
target | address | AccessControl contract or AccessManager address |
from | command | Keyword from |
account | address | Account to revoke from |
Examples
Section titled “Examples”load acl
set $token 0x9C58BAcC331c9aa871AFD802DB6379a98e80CEdbset $manager 0xc0dbDcA66a0636236fAbe1B3C16B1bD4C84bB1E1
# AccessControlacl:revoke MINTER_ROLE on $token from 0x4F2083f5fBede34C2714aFfb3105539775f7FE64
# AccessManageracl:revoke 42 on $manager from 0x4F2083f5fBede34C2714aFfb3105539775f7FE64- Role resolution follows the same rules as acl:grant: string roles are AccessControl bytes32 roles, numeric ids are AccessManager roles.
- The sender must hold the role's admin role.
See Also
Section titled “See Also”- acl:grant — grant a role
- @acl:hasRole — check membership