Assessment reports>Alkimiya>Threat Model>grantRole

Function: grantRole(byte[32] role, address account)

This function is used to grant a role to an account.

Inputs

  • role

    • Control: Arbitrary.

    • Constraints: None.

    • Impact: Role to grant.

  • account

    • Control: Arbitrary.

    • Constraints: None.

    • Impact: Address to grant role to.

Branches and code coverage

Intended branches

  • Invokes the _grantRole function to grant the role.

Negative behavior

  • Reverts if the caller is not the owner.

Zellic © 2024Back to top ↑