Bug 24192

Summary: Bugzilla wrong detection of MIME type for image/svg+xml
Product: freedesktop.org Reporter: worms_x <wormsxulla>
Component: BugzillaAssignee: fd.o Admin Massive <sitewranglers>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: wormsxulla
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description worms_x 2009-09-27 22:16:28 UTC
When a SVG file is attached to a bug, for instance here 

http://bugs.freedesktop.org/show_bug.cgi?id=23312 
or here:
http://bugs.freedesktop.org/show_bug.cgi?id=24191

the MIME type of the file is detected as image/svg, which is wrong. The correct file type is image/svg+xml.

To confirm this, compare:

http://www.corpsmoderne.net/~eve97/vertex/faceglass.svg (view source, you'll see that the file is image/svg+xml)

and 

http://bugs.freedesktop.org/attachment.cgi?id=28637 (file served with the wrong MIME type)

When a user will click the attachment above, with this wrong MIME type, his browser will prompt him for an action, and the user who will answer "download" innocently will have a new MIME type/Helper Application registered in the "Helper Applications" of such browsers as Firefox 2 and 3 and SeaMonkey 2.

This will make the browser detect all new local SVG files as image/svg, and it is a major annoyance, not only because SVG won't be displayed directly in the browser as they should be, but also because removing this wrong entry for MIME type is *difficult* in newest versions of Firefox and SeaMonkey (I don't know about other browsers such as Opera, and I'm not going to try :p )

See http://kb.mozillazine.org/index.php?title=File_types_and_download_actions

So Bugzilla should detect the correct file type, image/svg+xml, and this probably also applies to SVGZ, which is image/svg+xml also

See http://wiki.svg.org/MIME_Type
Comment 1 Tollef Fog Heen 2010-04-06 13:26:33 UTC
The newer bugzilla seems to have fixed this.  I've also updated the mime type of all existing image/svg attachments.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.