-
Notifications
You must be signed in to change notification settings - Fork 143
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
Authorise action managing tenant quotas for according tenants in API #536
Authorise action managing tenant quotas for according tenants in API #536
Conversation
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 👍
5db50b5
to
7dc1431
Compare
7dc1431
to
d1ac3c4
Compare
f0a6a5d
to
17afdce
Compare
This needs custom behaviour for role validation api requests - this is done by adding method custom_api_user_role_allows_method? in BaseController to decide if certain controller is allowing custom api validation. Authorisation action 'managing tenant quotas' according to tenants needs custom validation this is defined in Api::Subcollections::Quotas(api/subcollections/quotas.rb, included in TenantController) this custom validation is used only if api wants to authorise rbac_tenant_manage_quotas_tenant_<TENANT_ID> permission.
17afdce
to
a485c9a
Compare
@gtanzillo I avoided |
@miq-bot add_label hammer/yes, blocker, enhancement |
…as_tenant_product_feature_api Authorise action managing tenant quotas for according tenants in API (cherry picked from commit fadf393) https://bugzilla.redhat.com/show_bug.cgi?id=1468795
Hammer backport details:
|
this is PR is needed
This needs custom behaviour for role validation api requests -
this is done by adding method custom_api_user_role_allows_method?
in BaseController to decide if certain controller is allowing custom
api validation.
Authorisation action 'managing tenant quotas' according to tenants
needs custom validation this is defined in
Api::Subcollections::Quotas
(api/subcollections/quotas.rb
, included inTenantController
)this custom validation is used only if api wants to authorise
rbac_tenant_manage_quotas_tenant_
<TENANT_ID>
permission.this is used for authorisation of permission 'manage tenant quota' with using dynamic tenant features.
see desricption here ManageIQ/manageiq#18322
Links
https://bugzilla.redhat.com/show_bug.cgi?id=1468795