Skip to content

Feature/cleanup rbac naming - #495

Open
andreasfrisch wants to merge 8 commits into
developfrom
feature/cleanup-rbac-naming
Open

Feature/cleanup rbac naming#495
andreasfrisch wants to merge 8 commits into
developfrom
feature/cleanup-rbac-naming

Conversation

@andreasfrisch

Copy link
Copy Markdown
Contributor

🌟 Changes

  • Cleaned up namespaces
  • Moved system-admin permissions to other namespaces
  • Changed how 'removing elevated permissions' work for cloud engineers (this will require some frontend work too I think.)

@DFDS-Snyk

DFDS-Snyk commented Jul 28, 2026

Copy link
Copy Markdown

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues
Code Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

new List<Permission>
{
new(RbacNamespace.CapabilityManagement, "manage-permissions", "", RbacAccessType.Capability),
new(RbacNamespace.Capability, "manage-permissions", "", RbacAccessType.Capability),

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

With this rename, we now have an overlap of permissions. We have capability.manage-permissions for both the global and capability access type. And with how

{
var matching = allPermissions.First(ap => ap.Namespace.ToString() == p.Namespace && ap.Name == p.Name);
return new RolePermissionEntry(matching.Namespace, matching.Name, matching.AccessType);
works, it'll only ever pick the first one it finds. But I guess that's more on the RbacController that should have its behaviour fixed. Not sure we carry the AccessType in that request DTO though, would still make sense to fix it here I think.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

If I understand your concern, this should fix it: d87f8b5

It may require some frontend work, but we will not assign a permission to a wrong scope by accident at least.

Comment thread tools/config.json Outdated
"read-private",
"update",
"delete",
"delete-public",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm guessing this is only for local seeding? Either way, this is a change in permissions for Capability owners. This would allow them to delete public topics, something that we haven't previously allowed people unless they are cloud engineers.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

No, this is important.
It is primarily used for local seeding, but it can also be used by the 'bootstrapper' for rights in the system (the go script).

Will remove this

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