Technical Details
WebsiteDiscordOverviewSupport
  • Overview
  • Identity Protocol
    • Overview
    • Registry
    • Nodes & NFTs
      • Manufacturer
      • Vehicle ID
      • DeviceID
      • License
    • Auxiliary Contracts
      • Access Control
      • AdLicenseValidator
      • Eip712Checker
      • Mapper
    • Architecture
    • Pairing
  • Device Canonical Name
    • Overview
    • Contracts
      • DcnRegistry
      • DcnManager
      • PriceManager
      • Resolvers
  • Token & Governance
    • Token
    • Rewards
    • Governance
  • Data
    • Platform Components
    • DBC Decoding
    • Software-Only Connectivity
    • Data Storage
    • Validation
    • Data Dictionary
      • Sample Data
  • Hardware
    • Ecosystem
    • Open Hardware Spec
    • Manufacturing License
      • DIMO Memorandum of Understanding
      • Staking $DIMO for a Manufacturer License
    • Device License
      • Device Minting Certificate
      • Hardware and Security Audit
      • Testing and Quality Control
  • Abstraction
    • Sign In With Ethereum
    • Metatransactions
  • Security
    • Methods
    • Audits
    • User Privacy
Powered by GitBook
On this page
  1. Identity Protocol
  2. Auxiliary Contracts

Access Control

PreviousAuxiliary ContractsNextAdLicenseValidator

Last updated 1 year ago

Address:

Adapted version of to fit the storage-module architecture, that allows contracts to implement role-based mechanisms. When DIMORegistry is deployed, the DEFAULT_ADMIN_ROLE is assigned to the deployer in order to allow them to fully manage the system. This role also permits the creation, granting, and revoking of roles from other addresses.

To manage access to a function, we can use the onlyRole modifier and specify the role that the msg.sender must have to invoke that function.

function mockFunction(...) external onlyRole(ROLE) {…}

In the future, more functions may be added to increase the separation of concerns in the use of contracts and the roles of managers and users.

0x385b8Fa7A4bC0dB2149B1AB1928AfD21D551bd3d
Access Control from OpenZeppelin