Skip to content
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

feat: add AccessControl to managing ACL in WQ #487

Merged
merged 7 commits into from
Jan 13, 2023

Conversation

folkyatina
Copy link
Member

@folkyatina folkyatina commented Jan 12, 2023

Add role-based access control to WithdrawalQueue

There are three roles:

  • PAUSE_ROLE
  • RESUME_ROLE
  • FINALIZE_ROLE

and pause now is for finalization also

Copy link
Contributor

@arwer13 arwer13 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, except for a few comments.

contracts/0.8.9/WithdrawalQueue.sol Show resolved Hide resolved
contracts/0.8.9/WithdrawalQueue.sol Outdated Show resolved Hide resolved
contracts/0.8.9/WithdrawalQueue.sol Show resolved Hide resolved
contracts/0.8.9/WithdrawalQueue.sol Show resolved Hide resolved
@folkyatina folkyatina marked this pull request as ready for review January 12, 2023 13:19
Copy link
Contributor

@TheDZhon TheDZhon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for testnets 👍
Though, left some notes on the fields for the future.

bytes32 internal constant REQUESTS_PLACEMENT_RESUMED_POSITION =
keccak256("lido.WithdrawalQueue.requestsPlacementResumed");
/// Withdrawal queue resume/pause control storage slot
bytes32 internal constant RESUMED_POSITION = keccak256("lido.WithdrawalQueue.resumed");

/// Lido stETH token address to be set upon construction
address public immutable STETH;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be placed in unstructured storage eventually

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it? Not sure that it can be changed in a some way.

contracts/0.8.9/WithdrawalQueue.sol Show resolved Hide resolved
contracts/0.8.9/WithdrawalQueue.sol Outdated Show resolved Hide resolved
contracts/0.8.9/WithdrawalQueue.sol Show resolved Hide resolved
Base automatically changed from feature/withdrawal_tests to feature/shapella-upgrade January 13, 2023 10:58
Copy link
Contributor

@arwer13 arwer13 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM to merge 👍

@folkyatina folkyatina merged commit 3644e1a into feature/shapella-upgrade Jan 13, 2023
@folkyatina folkyatina deleted the feature/wq_roles branch January 13, 2023 13:28
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.

3 participants