server group can be shown and deleted by not owner tenant

Bug #1466390 reported by Rui Chen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Rui Chen

Bug Description

1. Exact version

$ git log -1
commit 045ee0336bde6e6ac5b41efe6d3da08462b4ec7d
Merge: 764c905 2a01a1b
Author: Jenkins <email address hidden>
Date: Thu Jun 18 06:24:08 2015 +0000

    Merge "Remove hv_type translation shim for powervm"

2. log files:

None

3. reproduce steps:

stack@devstack:/opt/stack/nova$ [master]$ source /home/devstack/openrc admin admin
stack@devstack:/opt/stack/nova$ [master]$ nova server-group-create chenrui_group affinity
+--------------------------------------+---------------+---------------+---------+----------+
| Id | Name | Policies | Members | Metadata |
+--------------------------------------+---------------+---------------+---------+----------+
| f11126e8-b29c-4fcb-8a56-20e6047f025c | chenrui_group | [u'affinity'] | [] | {} |
+--------------------------------------+---------------+---------------+---------+----------+
stack@devstack:/opt/stack/nova$ [master]$ source /home/devstack/openrc demo demo
stack@devstack:/opt/stack/nova$ [master]$ nova server-group-get f11126e8-b29c-4fcb-8a56-20e6047f025c
+--------------------------------------+---------------+---------------+---------+----------+
| Id | Name | Policies | Members | Metadata |
+--------------------------------------+---------------+---------------+---------+----------+
| f11126e8-b29c-4fcb-8a56-20e6047f025c | chenrui_group | [u'affinity'] | [] | {} |
+--------------------------------------+---------------+---------------+---------+----------+
stack@devstack:/opt/stack/nova$ [master]$ nova server-group-delete f11126e8-b29c-4fcb-8a56-20e6047f025c
Server group f11126e8-b29c-4fcb-8a56-20e6047f025c has been successfully deleted.
stack@devstack:/opt/stack/nova$ [master]$ source /home/devstack/openrc admin admin
stack@devstack:/opt/stack/nova$ [master]$ nova server-group-list
+----+------+----------+---------+----------+
| Id | Name | Policies | Members | Metadata |
+----+------+----------+---------+----------+
+----+------+----------+---------+----------+

Expected result:
* can't be shown and deleted by demo project

Actual result:
* can be shown and deleted by demo project

Rui Chen (kiwik-chenrui)
Changed in nova:
assignee: nobody → Rui Chen (kiwik-chenrui)
Changed in nova:
status: New → In Progress
Revision history for this message
Rui Chen (kiwik-chenrui) wrote :
Alex Xu (xuhj)
Changed in nova:
importance: Undecided → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/193117
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=d4d23124a54a62607f710c44a871c0810105729a
Submitter: Jenkins
Branch: master

commit d4d23124a54a62607f710c44a871c0810105729a
Author: Rui Chen <email address hidden>
Date: Thu Jun 18 21:01:08 2015 +0800

    Fix permission issue of server group API

    Server group was created by tenantA, but it can
    be shown and deleted by tenantB. Fix this permission
    issue, and update test cases.

    Change-Id: Ib0b96d536f7b085ef047cb8206de05f9bedc004f
    Closes-Bug: #1466390

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → liberty-rc1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: liberty-rc1 → 12.0.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.