-
-
Notifications
You must be signed in to change notification settings - Fork 17.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
different mime type for .bmp files since 4.16.0 #3486
Comments
The issue is that 2.0 is a different API (and we expose the mime API as parts of our API) and also requires Node.js 6+, both of which means we cannot use mime 2.0 in Express 4. The mime 1.x we are using right now is the only 1.x that does not have a security vulnerability so we cannot downgrade. Perhaps get it backported to mime 1.x and we can then upgrade our dependency. We treat changes to mime reaolutions as semver minor here, as we have done for many many years. This change was introduced in a minor version of Express so we don't really see an issue here. Basically if you can get mime package to release a new 1.x version with your desired mapping, we can update mime in our next minor version as usual, but otherwise there isn't an Express issue here (or anything we can change in this repository to make any adjustments). The mime module allows you to adjust mappings though their API for the entire process if you require('mime') and redefine .bmp which since it's global will change what Express will see as well. |
Ok, makes sense. Good to know. |
👍 also feel free to ping me here or whatever if there is a mime release with the change so we can get moving on it. We'll of course see the release some point after as well but a ping won't be a bother either :) |
@dougwilson What's the security issue with [Edit: Oh, are you talking about the RegExp DoS issue in https://github.com/broofa/mime/issues/167 ?] |
Yep. Those tools like nsp and snyk have 1.4.1 as the only "safe" version in the 1.x series. They flag modules that depend on (even just having a version ranges thag includes) older versions. |
Just published
@dougwilson Unfortunately I think the root issue here is the lack of facet prioritization I discuss in This is fixed in |
Isn't that issue about changing the As for removing the ES6 from mime 2.x, not sure if that's super necessary as far as Express 4.x is concerned, because the different API of |
The fundamental issue here is that neither
|
Right, and I don't disagree with anything you're saying. The issue is still open as well, though I was just noting for those subscribed to this issue that the mime-types module is not used by Express for the behavior the OP is reporting, so subscribing to that issue wouldn't be relevant to this issur is all. |
@broofa but |
The bmp issue was introduced in [email protected] when the mime-db dependency was upgraded from [email protected] to [email protected]. (The type definition for |
@Janpot @dougwilson : |
@broofa thanks a lot! |
Mime type for
.bmp
files use to beimage/bmp
inexpress < 4.15.0
. Now it isimage/x-ms-bmp
.I've been looking at the
mime
package and it looks like between version1.3.5
and2.0.0
it resolves toimage/x-ms-bmp
. in version> 2.0.0
it resolves toimage/bmp
againThe text was updated successfully, but these errors were encountered: