Skip to content

Refactor: Optimize permission checks #537

@ccremer

Description

@ccremer

Summary

As maintainer
I want to eliminate some permission checks
So that reduce complexity of the app

Context

With newer features in the control-api even the basic user gets more and more permissions.
See RBAC permission for a list of permissions.

In the Portal, we do a lot of permission checking, e.g. can-i list organizations or can-i update billingentity. Based on those permission query results, we enable/disable menus, buttons or change the behavior of components.

However, this checking is unnecessary if even the most basic user, including users from foreign IDPs, can do common operations anyway by just being allowed to log in to the control-api. If that's indeed the case, we can eliminate a lot of the permission checking in the code, thereby simplifying and reducing the complexity in the code.

Note: This isn't about eliminating all permission checks. We still need checks to determine whether we're Admin of a certain Organization or Billing entity for example. It's primarily about reducing the generic ones, e.g. list or create permissions.

Out of Scope

There is another issue to discuss how we're doing permission checks. This issue here discusses which permissions to check.

Further links

Acceptance Criteria

No response

Implementation Ideas

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions