Bug 1275782

Summary: Cloud Provisioning dialogs do not apply RBAC filtering to resources displayed in dialog fields
Product: Red Hat CloudForms Management Engine Reporter: Drew Bomhof <dbomhof>
Component: ProvisioningAssignee: Drew Bomhof <dbomhof>
Status: CLOSED ERRATA QA Contact: Aziza Karol <akarol>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.4.0CC: cpelland, dajohnso, gmccullo, jhardy, jprause, mfeifer, obarenbo
Target Milestone: GAKeywords: ZStream
Target Release: 5.4.4   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 5.4.4.1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1248181 Environment:
Last Closed: 2015-12-16 13:19:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1248181    
Bug Blocks:    

Comment 2 CFME Bot 2015-11-10 19:06:23 UTC
New commit detected on cfme/5.4.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=11809fb47e5ea2a2d4062bfd8ae9bf28b2097fed

commit 11809fb47e5ea2a2d4062bfd8ae9bf28b2097fed
Author:     Drew Bomhof <dbomhof>
AuthorDate: Tue Nov 3 12:09:18 2015 -0500
Commit:     Drew Bomhof <dbomhof>
CommitDate: Mon Nov 9 12:18:07 2015 -0500

    Apply RBac to cloud provisioning dialogs
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1275782
    
    Extracted behavior for applying Rbac into a new method - get_targets_for_source
    Applied Rbac for shared cloud provisioning dialogs - Availability Zone, Security Group, Instance Type (Flavor)
    Applied Rbac for Openstack provisioning dialog - Tenant
    
    Cherry Picked from PR(s): https://github.com/ManageIQ/manageiq/pull/5019
    https://github.com/ManageIQ/manageiq/pull/5322
    
    Cherry-pick was not 100% clean, had to do a lot of code rework to make this fix work on Rails 3.2

 vmdb/app/models/miq_provision_amazon_workflow.rb   |  25 +--
 vmdb/app/models/miq_provision_cloud_workflow.rb    |  13 +-
 .../app/models/miq_provision_openstack_workflow.rb |  17 +-
 .../models/miq_provision_amazon_workflow_spec.rb   | 171 +++++++++++++++++----
 .../miq_provision_openstack_workflow_spec.rb       | 153 +++++++++++++++++-
 5 files changed, 328 insertions(+), 51 deletions(-)

Comment 3 CFME Bot 2015-11-10 19:06:30 UTC
New commit detected on cfme/5.4.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=53ce326520da52098da4325136916f1483d150a1

commit 53ce326520da52098da4325136916f1483d150a1
Merge: b9c4d36 11809fb
Author:     Greg McCullough <gmccullo>
AuthorDate: Tue Nov 10 14:05:21 2015 -0500
Commit:     Greg McCullough <gmccullo>
CommitDate: Tue Nov 10 14:05:21 2015 -0500

    Merge branch 'cfme_apply_rbac_to_cloud' into '5.4.z'
    
    Apply RBac to cloud provisioning dialogs
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1275782
    
    Extracted behavior for applying Rbac into a new method - get_targets_for_ems
    Applied Rbac for shared cloud provisioning dialogs - Availability Zone, Security Group, Instance Type (Flavor)
    Applied Rbac for Openstack provisioning dialog - Tenant
    
    Cherry Picked from PR: https://github.com/ManageIQ/manageiq/pull/5019
    
    Cherry-pick was not 100% clean, had to do a lot of code rework to make this fix work on Rails 3.2
    
    See merge request !338

 vmdb/app/models/miq_provision_amazon_workflow.rb   |  25 +--
 vmdb/app/models/miq_provision_cloud_workflow.rb    |  13 +-
 .../app/models/miq_provision_openstack_workflow.rb |  17 +-
 .../models/miq_provision_amazon_workflow_spec.rb   | 171 +++++++++++++++++----
 .../miq_provision_openstack_workflow_spec.rb       | 153 +++++++++++++++++-
 5 files changed, 328 insertions(+), 51 deletions(-)

Comment 5 Aziza Karol 2015-12-09 11:50:58 UTC
When provisioning a cloud image the resources display in the provisioning dialog for items like Cloud Tenant and Availability Zone are filtered by RBAC.

For the logged in user only those resources gets displayed in the provision dialog's with tag visibility.


Verified:5.4.4.2.20151130143928_89a28ce

Comment 7 errata-xmlrpc 2015-12-16 13:19:02 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHSA-2015-2620.html