-
Notifications
You must be signed in to change notification settings - Fork 445
fix(govdao): make Tiers private to prevent external modification #5075
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
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: moul <94029+moul@users.noreply.github.com>
Signed-off-by: moul <94029+moul@users.noreply.github.com>
🛠 PR Checks SummaryAll Automated Checks passed. ✅ Manual Checks (for Reviewers):
Read More🤖 This bot helps streamline PR reviews by verifying automated checks and providing guidance for contributors and reviewers. ✅ Automated Checks (for Contributors):🟢 Maintainers must be able to edit this pull request (more info) ☑️ Contributor Actions:
☑️ Reviewer Actions:
📚 Resources:Debug
|
MikaelVallenet
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, related to this i made a PR with linter that add rule that would trigger exporting global var -> #5068
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, it would be a good idea to verify any similar issues in other realms
|
Exporting global vars make sense if they are safe objects. |
memberstore.Tierswas a public variable (var Tiers TiersByName) that exposed the underlying*avl.Tree. External realms could callmemberstore.Tiers.Set(...)to modify tier configurations,escalating voting power or corrupting governance data.
h/t @jeronimoalbi for the report.