Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[PLAT-16520][YBA CLI]RBAC commands don't run even if we have permissi…
…ons due to depending upon getting runtime config key. Summary: Switch the GetConfigurationKey API with the ListFeatureFlags API which does not depend on user auth permission Test Plan: Same user is with ROLE.READ permission is used in the following commands: ``` yba runtime-config scope key get -u 00000000-0000-0000-0000-000000000000 -n yb.rbac.use_new_authz Runtime Configuration Scope Key, Operation: Get - 401 Unauthorized ``` ``` yba rbac role list Name UUID Role Type ReadOnly 8c82c14d-b3ba-45aa-b7ff-f005689e8b9e System BackupAdmin 73f81706-4134-48f6-9db3-7f9f88eb5385 System ConnectOnly b0aa88a1-908e-4d86-bc75-e851b7f4e78a System Admin cf0e81cd-1442-4ef8-aa95-7f59bc6ff1ca System SuperAdmin f3619a4d-3ae4-45b4-81af-fbac8298a3fe System Access Manager 3c0d3992-7a29-4a70-8d12-2725657b5a62 Custom User Admin 423fc23d-af1c-4b5d-b503-8a8df4b53d62 Custom Sarthak 03cf79f0-ff86-4953-adb5-239683da4bf3 Custom universe_create 430b1fce-20e6-4469-9ce2-aab6f203cb95 Custom lingesh-readonly 55fd3743-78b2-4dcf-8930-4d45e036e26e Custom Universe Admin 45fe16f5-2f00-4c41-91f0-6e976dc42d46 Custom custom_sample_role 77142296-6f6d-43a6-a095-efd76e38b92c Custom SelectRead eda2d5dd-02d1-4f96-a959-e8c6b2b0ddbf Custom test2 cdcca230-e00b-4344-b74d-9de86ffee537 Custom kkannan-role 520ba59f-5ed3-4ff0-80a9-f3c768ba6f98 Custom test-cli-error 742e8f19-6e22-4b12-88ca-184449d153e9 Custom ``` Before RBAC is enabled: ``` yba rbac role list RBAC is not enabled in YugabyteDB Anywhere. Please enable `yb.rbac.use_new_authz` runtime configuration ``` Reviewers: skurapati Reviewed By: skurapati Subscribers: yugaware Differential Revision: https://phorge.dev.yugabyte.com/D41400
- Loading branch information