Bug 797584 - Removing a group from a system does not also remove group admin rights
Summary: Removing a group from a system does not also remove group admin rights
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Beaker
Classification: Retired
Component: inventory
Version: 0.8
Hardware: Unspecified
OS: Unspecified
unspecified
high vote
Target Milestone: ---
Assignee: Dan Callaghan
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-02-26 22:53 UTC by Dan Callaghan
Modified: 2019-05-22 13:41 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-04-26 07:16:20 UTC


Attachments (Terms of Use)

Description Dan Callaghan 2012-02-26 22:53:04 UTC
Description of problem:

When a user removes a group from a system, Beaker does not also clear the group admin rights (if any). As a result it is possible to have a system where a group has admin rights but does not appear in the Groups tab on the system page.


Steps to Reproduce:
1. On the Groups tab of the system page, add a group to a system
2. Grant that group admin rights
3. Remove the group
  
Actual results:

Group can still administer the system, even though it doesn't appear in the list of groups.


Expected results:

Admin rights should be removed when group is removed.

Comment 1 Dan Callaghan 2012-02-26 23:06:08 UTC
The following query can be used as a one-off cleanup, to remove group admin rights which should not be set:

DELETE FROM system_admin_map
WHERE (system_id, group_id) NOT IN
(SELECT system_id, group_id FROM system_group);

Comment 3 Dan Callaghan 2012-02-28 00:38:16 UTC
Patch pushed to Gerrit for review: http://gerrit.beaker-project.org/947


Note You need to log in before you can comment on or make changes to this bug.