missing X-Auth-Token Header yields Internal Server Error (500) instead of 401

Bug #1053474 reported by Ralf Haferkamp
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Identity (keystone)
Fix Released
Undecided
Ralf Haferkamp

Bug Description

Example:

curl http://<keystone>:35357/v2.0/tenants
{"error": {"message": "An unexpected error prevented the server from fulfilling your request. object of type 'NoneType' has no len()", "code": 500, "title": "Internal Server Error"}}

Expected result (and the actual behavior of essex):
{"error": {"message": "The request you have made requires authentication.", "code": 401, "title": "Not Authorized"}}

This seems to be specific to the sql and memcache backends.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to keystone (master)

Fix proposed to branch: master
Review: https://review.openstack.org/13368

Changed in keystone:
assignee: nobody → Ralf Haferkamp (rhafer)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to keystone (master)

Reviewed: https://review.openstack.org/13368
Committed: http://github.com/openstack/keystone/commit/c9a4141ab776427c5f77693630542450cd5167a7
Submitter: Jenkins
Branch: master

commit c9a4141ab776427c5f77693630542450cd5167a7
Author: Ralf Haferkamp <email address hidden>
Date: Thu Sep 20 17:29:12 2012 +0200

    Return a meaningful Error when token_id is missing

    To make keystone return HTTP 401 Unauthorized instead of 500 Internal Server
    Error when processing request that miss the X-Auth-Token Header.

    Fixes Bug 1053474

    Change-Id: Ib830fce7bb3b29fa1bc385f64c7c0ecdf5cd1644

Changed in keystone:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in keystone:
milestone: none → grizzly-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in keystone:
milestone: grizzly-1 → 2013.1
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.