Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1198731

Summary: power_compute_resources_vms permission is listed twice
Product: Red Hat Satellite Reporter: jaudet
Component: Users & RolesAssignee: Tomer Brisker <tbrisker>
Status: CLOSED CURRENTRELEASE QA Contact: Tazim Kolhar <tkolhar>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.1.0CC: bbuckingham, bkearney, cwelton, tkolhar
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
URL: http://projects.theforeman.org/issues/9837
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-08-12 14:01:04 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:

Description jaudet 2015-03-04 17:25:24 UTC
Description of problem:
To the best of my knowledge, each permission should be uniquely named. Unfortunately, there are two permissions named "power_compute_resources_vms". For example:

    >>> from robottelo import entities
    >>> entities.Permission(name='power_compute_resources_vms').search()
    [
        {
            u'name': u'power_compute_resources_vms',
            u'resource_type': u'ComputeResource',
            u'id': 26,
        },
        {
            u'name': u'power_compute_resources_vms',
            u'resource_type': None,
            u'id': 166,
        },
    ]

Version-Release number of selected component (if applicable):
Tested against Version 1.9.0-develop and Satellite-6.1.0-RHEL-7-20150303.0.

How reproducible:
100%

Steps to Reproduce:
1. Search for a permission named 'power_compute_resources_vms'

Actual results:
Two permissions.

Expected results:
One permission.

Additional info:

Comment 2 jaudet 2015-03-04 17:36:18 UTC
QE's test suite should be updated with a reference to this bug shortly. See: https://github.com/SatelliteQE/robottelo/pull/1966

Comment 3 RHEL Program Management 2015-03-05 02:26:39 UTC
Since this issue was entered in Red Hat Bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.

Comment 5 Tomer Brisker 2015-03-19 16:38:00 UTC
In fact permissions are only limited to have unique names per resource_type.
What you found here is one of several permissions added by foreman-docker plugin without setting resource_type - note that the second permission has resource_type: None.

Comment 6 Tomer Brisker 2015-03-19 16:43:04 UTC
Created redmine issue http://projects.theforeman.org/issues/9837 from this bug

Comment 7 Tomer Brisker 2015-03-26 12:33:31 UTC
This has been fixed upstream in foreman_docker by https://github.com/theforeman/foreman-docker/pull/88 
Moving to POST.

Comment 9 Tazim Kolhar 2015-04-28 10:11:11 UTC
VERIFIED :

rpm -qa | grep foreman
ruby193-rubygem-foreman_hooks-0.3.7-2.el7sat.noarch
foreman-selinux-1.7.2.13-1.el7sat.noarch
ruby193-rubygem-foreman_docker-1.2.0.9-1.el7sat.noarch
ruby193-rubygem-foreman-tasks-0.6.12.3-1.el7sat.noarch
rubygem-hammer_cli_foreman_tasks-0.0.3.3-1.el7sat.noarch
foreman-debug-1.7.2.17-1.el7sat.noarch
foreman-libvirt-1.7.2.17-1.el7sat.noarch
ruby193-rubygem-foreman_bootdisk-4.0.2.10-1.el7sat.noarch
foreman-compute-1.7.2.17-1.el7sat.noarch
foreman-ovirt-1.7.2.17-1.el7sat.noarch
rubygem-hammer_cli_foreman_bootdisk-0.1.2.5-1.el7sat.noarch
foreman-postgresql-1.7.2.17-1.el7sat.noarch
qe-sat6-rhel71.usersys.redhat.com-foreman-client-1.0-1.noarch
qe-sat6-rhel71.usersys.redhat.com-foreman-proxy-1.0-1.noarch
ruby193-rubygem-foreman_gutterball-0.0.1.9-1.el7sat.noarch
foreman-1.7.2.17-1.el7sat.noarch
foreman-gce-1.7.2.17-1.el7sat.noarch
ruby193-rubygem-foreman_discovery-2.0.0.9-1.el7sat.noarch
rubygem-hammer_cli_foreman-0.1.4.9-1.el7sat.noarch
foreman-vmware-1.7.2.17-1.el7sat.noarch
rubygem-hammer_cli_foreman_discovery-0.0.1.7-1.el7sat.noarch
foreman-proxy-1.7.2.4-1.el7sat.noarch
qe-sat6-rhel71.usersys.redhat.com-foreman-proxy-client-1.0-1.noarch
ruby193-rubygem-foreman-redhat_access-0.1.0-1.el7sat.noarch

steps:
1. Search for a permission named 'power_compute_resources_vms'
>>> from robottelo import entities
>>> entities.Permission(name='power_compute_resources_vms').search()
[{u'name': u'power_compute_resources_vms', u'resource_type': u'ComputeResource', u'id': 26}]

Comment 10 Bryan Kearney 2015-08-11 13:35:51 UTC
This bug is slated to be released with Satellite 6.1.

Comment 11 Bryan Kearney 2015-08-12 14:01:04 UTC
This bug was fixed in version 6.1.1 of Satellite which was released on 12 August, 2015.