|
ORE Studio 0.0.4
|
Manages commands related to RBAC (Role-Based Access Control). More...
#include <rbac_commands.hpp>

Static Public Member Functions | |
| static void | register_commands (cli::Menu &root_menu, ores::nats::service::nats_client &session, pagination_context &pagination) |
| Register RBAC-related commands. | |
| static void | process_list_permissions (std::ostream &out, ores::nats::service::nats_client &session) |
| Process a list permissions request. | |
| static void | process_list_roles (std::ostream &out, ores::nats::service::nats_client &session) |
| Process a list roles request. | |
| static void | process_get_role (std::ostream &out, ores::nats::service::nats_client &session, std::string role_identifier) |
| Process a get role request. | |
| static void | process_assign_role (std::ostream &out, ores::nats::service::nats_client &session, std::string account_id, std::string role_id) |
| Process an assign role request. | |
| static void | process_revoke_role (std::ostream &out, ores::nats::service::nats_client &session, std::string account_id, std::string role_id) |
| Process a revoke role request. | |
| static void | process_get_account_roles (std::ostream &out, ores::nats::service::nats_client &session, std::string account_id) |
| Process a get account roles request. | |
| static void | process_get_account_permissions (std::ostream &out, ores::nats::service::nats_client &session, std::string account_id) |
| Process a get account permissions request. | |
| static void | process_suggest_role_commands (std::ostream &out, ores::nats::service::nats_client &session, std::string username, std::string identifier) |
| Process a suggest role commands request. | |
Manages commands related to RBAC (Role-Based Access Control).
Provides shell commands for managing roles, permissions, and account-role assignments.
|
static |
Register RBAC-related commands.
Creates the roles and permissions submenus and adds RBAC operations. Also extends the accounts menu with role assignment commands.
Note: Roles and permissions don't support pagination at the protocol level yet, but the pagination_context is passed for consistency.
|
static |
Process a list permissions request.
Retrieves all permissions from the server and displays them.
| out | Output stream for results |
| session | Client session for connectivity. |

|
static |
Process a list roles request.
Retrieves all roles from the server and displays them.
| out | Output stream for results |
| session | Client session for connectivity. |

|
static |
Process a get role request.
Retrieves a specific role by name or ID and displays its details including all assigned permissions.
| out | Output stream for results |
| session | Client session for connectivity. |
| role_identifier | Role name or UUID |

|
static |
Process an assign role request.
Assigns a role to an account. Requires roles:assign permission.
| out | Output stream for results |
| session | Client session for connectivity. |
| account_id | Account ID UUID as a string. |
| role_id | Role ID UUID as a string. |

|
static |
Process a revoke role request.
Revokes a role from an account. Requires roles:revoke permission.
| out | Output stream for results |
| session | Client session for connectivity. |
| account_id | Account ID UUID as a string. |
| role_id | Role ID UUID as a string. |

|
static |
Process a get account roles request.
Retrieves all roles assigned to a specific account.
| out | Output stream for results |
| session | Client session for connectivity. |
| account_id | Account ID UUID as a string. |

|
static |
Process a get account permissions request.
Retrieves all effective permissions for a specific account.
| out | Output stream for results |
| session | Client session for connectivity. |
| account_id | Account ID UUID as a string. |

|
static |
Process a suggest role commands request.
Generates shell commands to assign all roles to an account. The account is identified by username and either hostname or tenant_id.
| out | Output stream for results |
| session | Client session for connectivity. |
| username | The username of the account. |
| identifier | Either a hostname or tenant_id UUID. |
