[nginx] MIME: changed type for bmp to image/bmp.

Maxim Dounin mdounin at mdounin.ru
Thu Mar 21 20:00:06 UTC 2024


details:   http://freenginx.org/hg/nginx/rev/28fbf78841dc
branches:  
changeset: 9229:28fbf78841dc
user:      Maxim Dounin <mdounin at mdounin.ru>
date:      Thu Mar 21 22:50:11 2024 +0300
description:
MIME: changed type for bmp to image/bmp.

At least Chrome, Safari, and Edge do no show image/x-ms-bmp when requested
directly (and instead show a download dialog), but do so for IANA-registered
MIME type image/bmp.  Mozilla considers doing the same
(https://bugzilla.mozilla.org/show_bug.cgi?id=1422725).

Further, Apache uses image/bmp since the bmp extension was added to mime.types
in Apache 1.3.6 (and also used it at least since 1.3.0 in magic-based type
detection).

The bmp extensions with the image/x-ms-bmp type was added in 863:57cb2052dcc6
(nginx 0.4.14), as a part of a large mime.types change, and it is not clear
why image/x-ms-bmp was used instead of image/bmp.

As such, changed MIME type for bmp files to image/bmp.

Requested by Yuriy Izorkin.

diffstat:

 conf/mime.types |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (19 lines):

diff --git a/conf/mime.types b/conf/mime.types
--- a/conf/mime.types
+++ b/conf/mime.types
@@ -16,6 +16,7 @@ types {
     text/x-component                                 htc;
 
     image/avif                                       avif;
+    image/bmp                                        bmp;
     image/png                                        png;
     image/svg+xml                                    svg svgz;
     image/tiff                                       tif tiff;
@@ -23,7 +24,6 @@ types {
     image/webp                                       webp;
     image/x-icon                                     ico;
     image/x-jng                                      jng;
-    image/x-ms-bmp                                   bmp;
 
     font/woff                                        woff;
     font/woff2                                       woff2;



More information about the nginx-devel mailing list