Wrong exception type HTTPBadRequest is raised
Bug #1281904 reported by
Haiwei Xu
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Undecided
|
Haiwei Xu |
Bug Description
When user without admin permission wants to get a list of servers
which are in 'deleted' state, currently it raises HTTPBadRequest.
The code is:
231 if search_
232 if context.is_admin:
233 search_
234 else:
235 msg = _("Only administrators may list deleted instances")
236 raise exc.HTTPBadRequ
This should be changed to HTTPForbidden exception.
Changed in nova: | |
assignee: | nobody → Haiwei Xu (xu-haiwei) |
Changed in nova: | |
status: | New → In Progress |
Changed in nova: | |
milestone: | none → icehouse-rc1 |
Changed in nova: | |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | icehouse-rc1 → 2014.1 |
To post a comment you must log in.
Reviewed: https:/ /review. openstack. org/74552 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=544745f9da3 245a71d771cff26 dc6d0255bb0470
Committed: https:/
Submitter: Jenkins
Branch: master
commit 544745f9da3245a 71d771cff26dc6d 0255bb0470
Author: Haiwei Xu <email address hidden>
Date: Wed Feb 19 04:32:38 2014 +0900
Change exception type from HTTPBadRequest to HTTPForbidden
When user without admin permission wants to get a list of servers
which are in 'deleted' state, currently it raises HTTPBadRequest.
This should be changed to HTTPForbidden exception.
Change-Id: I29da5f055c69e8 aba66ffb068a360 1ae69b2fc94
Closes-Bug: #1281904