All users were logged out of Bugzilla on October 13th, 2018

Firefox should support .tar.lz downloads

NEW
Unassigned

Status

()

P5
normal
a year ago
a year ago

People

(Reporter: eggert, Unassigned)

Tracking

54 Branch
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

a year ago
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:54.0) Gecko/20100101 Firefox/54.0
Build ID: 20170612122310

Steps to reproduce:

1. Run Mozilla Firefox 54.0 on Ubuntu 16.04.2 LTS x86-64.

2. Visit https://www.iana.org/time-zones

3. Click on "tzdb-2017b.tar.lz" link for "Complete Distribution (Data, Code and Extras)"


Actual results:

A popup appears, saying "You have chosen to open tzdb-2017b.tar.lz which is: Lzip archive from: https://www.iana.org. Would you like to save this file?"


Expected results:

The popup's last question should be "What should Firefox do with this file?", with the radio buttons "Open with ...", "Save file", where the "..." stands for a choice of Archive Manager (default), or Other.
the website returns the file with "Content-Type: application/octet-stream",
that could be the reason why Firefox doesn't recognize the handler application.

do you know what MIME-type is associated with .tar.lz on your system and also what application is associated to it?
(Reporter)

Comment 2

a year ago
> the website returns the file with "Content-Type: application/octet-stream",

Yes, I have asked the website sysadmins to fix that. Still, I assume Firefox does the right thing for .tar.gz files when the Content-Type is application/octet-stream, and it should do something similar for .tar.lz.

> do you know what MIME-type is associated with .tar.lz on your system and also
> what application is associated to it?

None, as far as I can tell. ~/.mozilla/firefox/i3pgjy4i.default/mimeTypes.rdf does not mention the lz extension or the lzip application. It does have an entry for .tgz, and another for .gz with application/g-zip, In Firefox the URL about:preferences#applications has one entry labeled "Gzip archive" and another labeled "TGZ file", but nothing for lzip that I can see. This seems to correspond to my mimeTypes.rdf file. I have never edited the mimeTypes.rdf file, as far as I know: this is just the file that Firefox set up for me.
(In reply to Paul Eggert from comment #2)
> > do you know what MIME-type is associated with .tar.lz on your system and also
> > what application is associated to it?
> 
> None, as far as I can tell.
> ~/.mozilla/firefox/i3pgjy4i.default/mimeTypes.rdf does not mention the lz
> extension or the lzip application.

I meant the system-wide thing, not a configuration for Firefox.
(Reporter)

Comment 4

a year ago
> I meant the system-wide thing, not a configuration for Firefox.

If you're referring to /etc/mime.types, that file has no lines for .lz files. It does have lines for .gz and .tgz. I just now filed an Ubuntu bug report about this here:

https://bugs.launchpad.net/ubuntu/+source/mime-support/+bug/1703238

If I add the line "application/x-lzip lz" to ~/mime.types, the Firefox popup suggests file-roller. However, this is still not the same as the popup for the .gz file, which suggests Archive Manager. And file-roller mishandles the file. So we're still not there yet. However, this appears to be a problem outside the scope of Firefox so I suppose we should close the bug report.
There should be another places that defines the association between MIME-type and handler application,
like Archive Manager for tar gz.

so, it would be nice to check if the file can be handled by Archive Manager on your system,
maybe from filer or somewhere
Component: Untriaged → File Handling
Product: Core → Firefox
(Reporter)

Comment 6

a year ago
If I use nautilus to visit a directory containing both a .tar.gz and a .tar.lz file, nautilus lists "Tar archive (gzip-compressed) (application/x-compressed-tar)" and "Lzip archive (application/x-lzip)" as their properties. If I double-click on the .tar.gz file's icon, nautilus opens file-roller to do the equivalent of gzip -d and tar -tv all at once. If I double-click on the .tar.lz file's icon, nautilus opens file-roller to do the equivalent of lzip -d, and I can then click on file-roller's tzdb-2017b.tar icon to do the equivalent of tar -tv.

So the .tar.lz file can be handled by the archive manager on my system (Ubuntu 16.04.2 LTS x86-64), albeit a bit less nicely than it handles the .tar.gz file.

I think this stuff is governed by the contents of files under /usr/share/applications, which I can give you further details about if you're interested.

Updated

a year ago
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P5
You need to log in before you can comment on or make changes to this bug.