RequestContext 'auth_tok' inconsistent with RPCContext

Bug #1152826 reported by Vipul Sabhaya
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oslo-incubator
Fix Released
Undecided
Davanum Srinivas (DIMS)
Grizzly
Fix Released
Undecided
Davanum Srinivas (DIMS)

Bug Description

RequestContext holds the Auth-Token in an attributed named 'auth_tok'. When this context is serialized to amqp (pack_context), its to_dict method is called and the resulting dictionary converts the key to 'auth_token'.

After unpacking into RPCContext, the Auth-Token now is only accessible via the 'auth_token' attribute instead. So if a RPC Service intends to use it, it has to be aware of the changed attribute name.

    def to_dict(self):
        return {'user': self.user,
                'tenant': self.tenant,
                'is_admin': self.is_admin,
                'read_only': self.read_only,
                'show_deleted': self.show_deleted,
                'auth_token': self.auth_tok, <-----------------------
                'request_id': self.request_id}

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

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

Changed in oslo:
assignee: nobody → Davanum Srinivas (DIMS) (dims-v)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo-incubator (master)

Reviewed: https://review.openstack.org/24027
Committed: http://github.com/openstack/oslo-incubator/commit/ab50ac0c9b8e9dbf2a2f353f68c2b7f397175df2
Submitter: Jenkins
Branch: master

commit ab50ac0c9b8e9dbf2a2f353f68c2b7f397175df2
Author: Davanum Srinivas <email address hidden>
Date: Sun Mar 10 19:04:42 2013 -0400

    Fix inconsistency with auth_tok/auth_token

    Switch to using auth_token instead of auth_ok

    Fixes LP# 1152826

    Change-Id: I56569c1fa8f29b0474440c40644729d436d41c7b

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