commit b65d506a5f9d9b2b20777a9aceb44a8ffed6a5de
Author: Russell Bryant <email address hidden>
Date: Thu Jun 27 21:00:05 2013 +0000
Make flavors is_public option actually work
When you create a flavor, you can set an is_public flag to be True or
False. It is True by default. When False, the intention is that the
flavor is only accessible by an admin, unless you use the flavor_access
API extension to grant access to specific tenants.
Unfortunately, the only place in the code where this was being enforced
was when listing flavors through the API. It would filter out the
non-public ones for a non-admin. Otherwise, the flavor was accessible.
You could get the details, and you could boot an instance with it, if
you figured out a valid flavor ID.
This patch adds enforcement down in the db layer. It also fixes one
place in the API where the context wasn't passed down to enable the
enforcement to happen.
Reviewed: https:/ /review. openstack. org/34963 github. com/openstack/ nova/commit/ b65d506a5f9d9b2 b20777a9aceb44a 8ffed6a5de
Committed: http://
Submitter: Jenkins
Branch: master
commit b65d506a5f9d9b2 b20777a9aceb44a 8ffed6a5de
Author: Russell Bryant <email address hidden>
Date: Thu Jun 27 21:00:05 2013 +0000
Make flavors is_public option actually work
When you create a flavor, you can set an is_public flag to be True or
False. It is True by default. When False, the intention is that the
flavor is only accessible by an admin, unless you use the flavor_access
API extension to grant access to specific tenants.
Unfortunately, the only place in the code where this was being enforced
was when listing flavors through the API. It would filter out the
non-public ones for a non-admin. Otherwise, the flavor was accessible.
You could get the details, and you could boot an instance with it, if
you figured out a valid flavor ID.
This patch adds enforcement down in the db layer. It also fixes one
place in the API where the context wasn't passed down to enable the
enforcement to happen.
Fix bug 1194093.
Change-Id: I5b37fa0bb19683 fe1642fd8122254 7d4a317054e