Skip to content

Conversation

@maximopalopoli
Copy link
Collaborator

@maximopalopoli maximopalopoli commented Jan 12, 2026

TITLE

Description

This change lets us check the addresses assigned to each role without much effort.

How to test

To check the address associated with both roles:

// Owner role
cast call 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "getRoleMember(bytes32,uint256)(address)" \
  b19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e 0

// Admin role
cast call 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "getRoleMember(bytes32,uint256)(address)" \
  a49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775 0

To check the number of addresses associated with those roles:

// Owner role
cast call 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "getRoleMemberCount(bytes32)(uint256)" \
  b19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e

// Admin role
cast call 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "getRoleMemberCount(bytes32)(uint256)" \
  a49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775

To grant a role to a new address:

// Owner role
cast send 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "grantRole(bytes32,address)" \
  b19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e <address-to-grant> \
  --private-key 0x4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356
  
// Admin role
cast send 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "grantRole(bytes32,address)" \
  a49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775 <address-to-grant> \
  --private-key 0x4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356

To revoke a role:

// Owner role
cast send 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "revokeRole(bytes32,address)" \
  b19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e <address-to-revoke> \
  --private-key 0x4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356

// Admin role
cast send 0x922D6956C99E12DFeB3224DEA977D0939758A1Fe "revokeRole(bytes32,address)" \
  a49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775 <address-to-revoke> \
  --private-key 0x4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356

Type of change

Please delete options that are not relevant.

  • New feature
  • Bug fix
  • Optimization
  • Refactor

Checklist

  • “Hotfix” to testnet, everything else to staging
  • Linked to Github Issue
  • This change depends on code or research by an external entity
    • Acknowledgements were updated to give credit
  • Unit tests added
  • This change requires new documentation.
    • Documentation has been added/updated.
  • This change is an Optimization
    • Benchmarks added/run
  • Has a known issue
  • If your PR changes the Operator compatibility (Ex: Upgrade prover versions)
    • This PR adds compatibility for operator for both versions and do not change crates/docs/examples
    • This PR updates batcher and docs/examples to the newer version. This requires the operator are already updated to be compatible

@maximopalopoli maximopalopoli self-assigned this Jan 12, 2026
@maximopalopoli maximopalopoli marked this pull request as ready for review January 12, 2026 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants