-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ACL: create optimized version of ACL that is only used to set up new organizations #546
Comments
I really like this idea and I think we should definitely explore it. From your proposal, I'm a bit hesitant about using the Another option could be to just some of these features to the regular ACL:
An alternative to having explicit root entities could be to assume that an entity with the |
I feel like this would be a useful pattern, and organizations could presumably opt-out of using the feature in some way similar to how you can burn permissions now. Most organizations have some entity (or process) which can be considered the root authority anyways. |
A lot of templates use
acl.createPermission()
andacl.grantPermission()
many, many times.The overhead of each call is quite high, requiring 10-30 duplicate
auth
,noPermissionManager
, andonlyPermissionManager
checks, as well as proxy call overheads. Each of these adds some 10k-50k gas in overhead.Moreover, multiple times we assign "temporary" permissions to the factory to allow it to access functionality, each time costing upwards of 200-300k in gas.
Instead, we can provide a more efficient version of the ACL that allows you to set multiple permissions at the same time, while also simplifying the authentication checks, and swap out its implementation for the full version of the ACL at the end. For this more efficient ACL, I would consider any entity holding the "CREATE_PERMISSIONS_ROLE" as having full root access over the organization.
The text was updated successfully, but these errors were encountered: