XML middleware will try to convert everything even if it's not json

Bug #1262057 reported by Jamie Lennox
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Identity (keystone)
Won't Fix
Undecided
Jamie Lennox

Bug Description

There are certain routes like /v2.0/certificates/ca that return PEM files that do not return the standard choice of JSON or XML data. If you request these routes with XML in the Accept field (like if you hit it with a browser) then the XML middleware will kick in and assume that, like other requests, it needs to load it as json then convert it to xml.

This is obviously wrong. We should only be doing XML processing if we understand the content we are trying to convert, and it is better to return something that is not on the Accept list than return an error (in JSON no less).

Tags: xml
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/62809

Changed in keystone:
assignee: nobody → Jamie Lennox (jamielennox)
status: New → In Progress
Revision history for this message
Dolph Mathews (dolph) wrote :

Code review is long abandoned.

tags: added: xml
Changed in keystone:
status: In Progress → Incomplete
Revision history for this message
David Stanek (dstanek) wrote :

The XML middleware has been marked as deprecated so I don't see a lot of work happening here.

Changed in keystone:
status: Incomplete → Won't Fix
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.