diff options
| author | Brian Lamar <brian.lamar@rackspace.com> | 2011-04-15 15:01:17 -0400 |
|---|---|---|
| committer | Brian Lamar <brian.lamar@rackspace.com> | 2011-04-15 15:01:17 -0400 |
| commit | b571bf6bb329e3bb085987554461c411ef56b330 (patch) | |
| tree | da3132c6d8e1fe27afb1591da9037fac0bcb8022 /nova/api | |
| parent | 394b8ffac5f7361a163b320afdc824fda7ef0406 (diff) | |
Explicitly tell a user that they need to authenticate against a version root.
Diffstat (limited to 'nova/api')
| -rw-r--r-- | nova/api/openstack/auth.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/nova/api/openstack/auth.py b/nova/api/openstack/auth.py index 42c23785a..311e6bde9 100644 --- a/nova/api/openstack/auth.py +++ b/nova/api/openstack/auth.py @@ -87,9 +87,10 @@ class AuthMiddleware(wsgi.Middleware): # honor it path_info = req.path_info if len(path_info) > 1: - msg = _("Authentication requests must be made against /<version>") + msg = _("Authentication requests must be made against a version " + "root (e.g. /v1.0 or /v1.1).") LOG.warn(msg) - return faults.Fault(webob.exc.HTTPUnauthorized()) + return faults.Fault(webob.exc.HTTPUnauthorized(explanation=msg)) try: username = req.headers['X-Auth-User'] |
