X
Tap here to go to the mobile version of the site.

Support Forum

Firefox recognizes download file type as text regardless of content type response header

Posted

I have Firefox ESR 52.9.0 (32-bit) installed on Windows XP. When I download a file, it always recognizes it as text and adds a "txt" extension to it. This is done regardless of the server's HTTP response headers, indicating the file type as either "application/octet-stream" or "application/vnd.ms-access" or anything else for that matter.

Same version on different operating systems may differ in behavior. I tried uninstalling and re-installing and removing all plugins/extensions but it doesn't seem to make a difference.

I have Firefox ESR 52.9.0 (32-bit) installed on Windows XP. When I download a file, it always recognizes it as text and adds a "txt" extension to it. This is done regardless of the server's HTTP response headers, indicating the file type as either "application/octet-stream" or "application/vnd.ms-access" or anything else for that matter. Same version on different operating systems may differ in behavior. I tried uninstalling and re-installing and removing all plugins/extensions but it doesn't seem to make a difference.
Quote

Additional System Details

Application

  • User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.132 Safari/537.36

More Information

Question owner

Here are screenshots from same version of browser on two different operating systems.

Here are screenshots from same version of browser on two different operating systems.
Was this helpful to you?
Quote
alex_mayorga
  • Top 25 Contributor
  • Moderator
365 solutions 2869 answers

Hi Jonathan!

Prior to helping you here I'd strongly encourage you to upgrade to a supported operating system, per https://support.microsoft.com/en-us/lifecycle/search?alpha=Microsoft%20Windows%20XP%20Service%20Pack%202 the version you currently use ceased to be supported on 4/8/2014.

https://distrochooser.de/en/ is generally a good starting point to find an alternative.

Once that is taken care of, please also update the version of Firefox ESR per https://www.mozilla.org/en-US/firefox/68.1.0/releasenotes/

If you still can reproduce the issue then, please let us know here and we'd be happy to help.

Please excuse me but I strongly believe that continuing to use unsupported well known vulnerable versions of both the OS and browser is a disservice to yourself and harmful for the web as a whole.

Thanks!

Hi Jonathan! Prior to helping you here I'd strongly encourage you to upgrade to a supported operating system, per https://support.microsoft.com/en-us/lifecycle/search?alpha=Microsoft%20Windows%20XP%20Service%20Pack%202 the version you currently use ceased to be supported on 4/8/2014. https://distrochooser.de/en/ is generally a good starting point to find an alternative. Once that is taken care of, please also update the version of Firefox ESR per https://www.mozilla.org/en-US/firefox/68.1.0/releasenotes/ If you still can reproduce the issue then, please let us know here and we'd be happy to help. Please excuse me but I strongly believe that continuing to use unsupported well known vulnerable versions of both the OS and browser is a disservice to yourself and harmful for the web as a whole. Thanks!
Was this helpful to you?
Quote

Question owner

Some browser versions are beyond our control. However, this also happens with 68.0.2 on Windows 10.

Some browser versions are beyond our control. However, this also happens with 68.0.2 on Windows 10.
Was this helpful to you?
Quote
alex_mayorga
  • Top 25 Contributor
  • Moderator
365 solutions 2869 answers

Hi Jonathan!

Could you please share a URL where this can be reproduced?

Have you tried https://support.mozilla.org/en-US/kb/troubleshoot-firefox-issues-using-safe-mode yet?

Thanks!

Hi Jonathan! Could you please share a URL where this can be reproduced? Have you tried https://support.mozilla.org/en-US/kb/troubleshoot-firefox-issues-using-safe-mode yet? Thanks!
Was this helpful to you?
Quote

Question owner

Unfortunately I cannot share the link, as it is our business product which requires username/password. I did try starting Firefox in safe mode (without any plugins/extensions) but it didn't make a difference.

Unfortunately I cannot share the link, as it is our business product which requires username/password. I did try starting Firefox in safe mode (without any plugins/extensions) but it didn't make a difference.
Was this helpful to you?
Quote
alex_mayorga
  • Top 25 Contributor
  • Moderator
365 solutions 2869 answers

Hi Jonathan!

Please review https://support.mozilla.org/en-US/kb/change-firefox-behavior-when-open-file#w_changing-download-actions it might be you ought to add the content type on Firefox.

Please let us know if this solves your question.

Thanks!

Hi Jonathan! Please review https://support.mozilla.org/en-US/kb/change-firefox-behavior-when-open-file#w_changing-download-actions it might be you ought to add the content type on Firefox. Please let us know if this solves your question. Thanks!
Was this helpful to you?
Quote

Question owner

Unfortunately, it doesn't. I don't see the content type there, which may be the problem. However, I don't see a way of editing this and adding a new content type, which may very well solve the issue.

Unfortunately, it doesn't. I don't see the content type there, which may be the problem. However, I don't see a way of editing this and adding a '''new''' content type, which may very well solve the issue.
Was this helpful to you?
Quote
cor-el
  • Top 10 Contributor
  • Moderator
17470 solutions 157890 answers

You can inspect the MIME database key with the registry editor (regedit.exe) and do a search for that MIME type (file extension) via Ctrl+F. Be cautious with editing the registry as there is NO UNDO possible: all changes are applied immediately. You can export key(s) in the registry editor before making changes. You can check specific file extension keys (e.g. .mdb) in the registry with the registry editor.

  • HKEY_CLASSES_ROOT\.xxx

You can check a possibly linked MIME type in the MIME Database registry key.

  • HKEY_CLASSES_ROOT\MIME\Database\Content Type\
You can inspect the MIME database key with the registry editor (regedit.exe) and do a search for that MIME type (file extension) via Ctrl+F. Be cautious with editing the registry as there is NO UNDO possible: all changes are applied immediately. You can export key(s) in the registry editor before making changes. You can check specific file extension keys (e.g. .mdb) in the registry with the registry editor. * HKEY_CLASSES_ROOT\.xxx You can check a possibly linked MIME type in the MIME Database registry key. * HKEY_CLASSES_ROOT\MIME\Database\Content Type\
Was this helpful to you?
Quote

Question owner

Thanks, I was afraid that was the solution. However, this is too "invasive", and clients' browsers are beyond our control.

Thanks, I was afraid that was the solution. However, this is too "invasive", and clients' browsers are beyond our control.
Was this helpful to you?
Quote
jscher2000
  • Top 10 Contributor
8690 solutions 71037 answers

On your Firefox 68 installation, you can use my extension to log the content-type headers sent by the server:

https://addons.mozilla.org/firefox/addon/content-type-fixer/

Click the Zzzz button to start logging; that also enables a drop-down menu to view the log (Add/Edit).

If the server is sending text/plain, that probably means the .mdb extension is not mapped to a content type. I assume it must be a Linux server, since I'm pretty sure Microsoft IIS would have that mapped?

For Apache or similar, you define new content types using AddType.

https://httpd.apache.org/docs/2.4/mod/mod_mime.html#addtype

Depending on your hosting, you may need to use .htaccess if you can't update the central config files.

On your Firefox 68 installation, you can use my extension to log the content-type headers sent by the server: https://addons.mozilla.org/firefox/addon/content-type-fixer/ Click the Zzzz button to start logging; that also enables a drop-down menu to view the log (Add/Edit). If the server is sending text/plain, that probably means the .mdb extension is not mapped to a content type. I assume it must be a Linux server, since I'm pretty sure Microsoft IIS would have that mapped? For Apache or similar, you define new content types using AddType. https://httpd.apache.org/docs/2.4/mod/mod_mime.html#addtype Depending on your hosting, you may need to use .htaccess if you can't update the central config files.
Was this helpful to you?
Quote
Ask a question

You must log in to your account to reply to posts. Please start a new question, if you do not have an account yet.