Bugzilla does not send correct Content-Type for JSON template
RESOLVED
FIXED
in Bugzilla 3.6
Status
()
People
(Reporter: gerv, Assigned: gerv)
Tracking
Details
(Whiteboard: bzapi)
Attachments
(1 attachment)
709 bytes,
patch
|
mkanat
:
review+
|
Details | Diff | Splinter Review |
Bugzilla can be extended in a supported fashion by dropping in new templates. http://www.bugzilla.org/docs/tip/en/html/cust-templates.html The template to be used for a given request is chosen using the "ctype" parameter. However, Bugzilla currently only knows the correct Content Type for a few ctypes. The list is in Bugzilla/Constants.pm, the constant "contenttypes". It knows: html, rdf, atom, xml, js, csv, png and ics. If an admin adds a new template which is not one of those types, Bugzilla will not send a Content-Type at all. :-(( This means that, among other things, client software may default to guessing the type as text/html and also the charset as ISO-8859-1, both of which are incorrect, and the latter of which could lead to data corruption. For these reasons Bugzilla should know about a good set of common content types admins may use. In particular, JSON. Gerv
(Assignee) | ||
Comment 1•9 years ago
|
||
Created attachment 447769 [details] [diff] [review] Patch v.1 Trivial patch. Gerv
Comment 2•9 years ago
|
||
Comment on attachment 447769 [details] [diff] [review] Patch v.1 Reasonable.
Attachment #447769 -
Flags: review?(mkanat) → review+
Updated•9 years ago
|
Flags: approval3.6+
Flags: approval+
Target Milestone: --- → Bugzilla 3.6
(Assignee) | ||
Comment 3•9 years ago
|
||
http://bzr.mozilla.org/bugzilla/3.6/revision/7103 http://bzr.mozilla.org/bugzilla/trunk/revision/7200 (I've fixed the bug in my scripts which seems to have recorded the author as ''.) Gerv
Status: ASSIGNED → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•