Opened 7 years ago

Closed 7 years ago

Last modified 5 years ago

#11660 closed (fixed)

mod_python handler does not set inbound content-type correctly

Reported by: Nowell Strite Owned by: nobody
Component: HTTP handling Version: 1.1
Severity: Keywords: mod_python content-type
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

The mod_python handler does not set the inbound content-type properly (request.META['Content-Type']) instead setting it to None. This is problematic for things such as RESTful services, where we might want to specify the inbound payload content-type (application/json, text/xml, etc.). This patch retrieves the content-type properly; in the same way a previous ticket does http://code.djangoproject.com/ticket/5611 for a different portion request parsing.

Attachments (2)

mod_python_content_type_bug.patch (1.1 KB) - added by Nowell Strite 7 years ago.
mod_python_meta_bugs.patch (1.6 KB) - added by Tareque Hossain 7 years ago.
A better patch to fix the other "this may be wrong" bug

Download all attachments as: .zip

Change History (6)

Changed 7 years ago by Nowell Strite

Changed 7 years ago by Tareque Hossain

Attachment: mod_python_meta_bugs.patch added

A better patch to fix the other "this may be wrong" bug

comment:1 Changed 7 years ago by Russell Keith-Magee

Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset

(In [11528]) Fixed #11660 -- Corrected the CONTENT_TYPE and CONTENT_LENGTH headers provided by the mod_python handler. Thanks to Nowell Strite and Tareque Hossain for the report and fix.

comment:2 Changed 7 years ago by Alex Gaynor

Resolution: fixed
Status: newclosed

Fail.

comment:3 Changed 7 years ago by Russell Keith-Magee

(In [11530]) [1.1.X] Fixed #11660 -- Corrected the CONTENT_TYPE and CONTENT_LENGTH headers provided by the mod_python handler. Thanks to Nowell Strite and Tareque Hossain for the report and fix.

Merge of r11528 from trunk.

comment:4 Changed 5 years ago by Jacob

milestone: 1.2

Milestone 1.2 deleted

Note: See TracTickets for help on using tickets.
Back to Top