How to install firefox (non snap)

@Chris:

Thanks for the thorough explanation . . . like all things, each has their cost/benefit ratio . . . . I’m essentially an end-user, but I like to stay up with the newest releases . . . on a number of OSs. So that means I don’t get under the hood much on any one of them, unless something breaks . . . .

So far, other than longer boot time for Jammy compared to my other systems, I can’t say it’s broke . . . . I don’t mind testing stuff out, to keep it amusing, but then, there’s always another release or upgrade coming down the pike, etc. Tempus fugit and so forth.

3 Likes

I do agree with you. Jammy is mostly fine, but i don’t notice a long boot time. Everything has to giveth and taketh…

Of course you can.

2022-04-20_12-43

That’s an extension installed in the Snap version of Firefox.

1 Like

Yes, but certain extensions like keypass and video download helper don’t work because of no native messaging protocol.

That’s a far cry from the statement you made.

I’ve never tried any of those - but you might want to see if there’s a permissions issue? I really don’t know. But, yeah, you can install (and have work) extensions. If a few specific ones don’t work, look for alternatives until everything is sorted out. (Or just use regular Firefox.)

Yeah, that’s what I’m doing right now, using the regular Mozilla version.

I don’t normally use Firefox, but I’ll try to get some time in the next day or three to see if I can make one or both of those extensions work. I’m a bit bandwidth constrained for the foreseeable future, so it’ll be a minute. You can actually change Snap permissions so there might be something there.

1 Like

Mozilla have acknowledged a number of bugs are reported in the firefox snap package, and have given assurances they’ll get fixed asap; though did say many will be corrected post-release date for Ubuntu 22.04 LTS.

5 Likes

As a Lubuntu Council member I would like to address a few things above.

The question is, how important is “snap” to Lubuntu and/or the genral Ubuntu operating system?? They seem to be diving into it with enthusiasm

@guiverc addressed what the snap packaging system is but I would like to address the “how important” part of this from a Lubuntu standpoint. The system and configuration we ship is what we feel comfortable to support either directly or with upstream Ubuntu help. One of the great things about Ubuntu (and Linux/open source based things) is there is a great deal of choice in what you can do with it after. There is complete control to do what you want. We (the Lubuntu Team) are far too small to account for every variable which is why our team needs to stick to supporting what we offer out of the box. It isn’t that we won’t try to help you should you choose to go your own path but we only have a limited amount of time and knowledge so in some regards you are on your own.

All of that being said, the decision to switch to the Firefox snap was not necessarily the Lubuntu Team’s preference, this is the first snap we have shipped by default. As I previously mentioned we are a small team and can not support our own browser, thus we look to our upstream offerings. We could have chosen Falkon, as that is still in the Ubuntu repositories and is now seeing some regular releases from the upstream developers. I would actually suggest that as a possible alternative or secondary browser option. It does have limitations though, extension support is one of the areas. In addition, DRM online video is another area. If those things don’t matter too much to you, it is a great choice. Ultimately we went with Firefox as a snap because we feel it offers the most functionality and will give (generally speaking) the most complete browser experience.

Snap Firefox takes 15 seconds to launch? Its annoying, since I have an nvme SSD.

It is true that the first time Firefox is loaded in your current session it takes more time and it is annoying. That being said, it only happens on first load, after that it takes the same time as the other package formats. I (and this is me speaking, not the council) find it a strange thing to get hung up on since it is a one time thing.

I’ve noticed that my Lubuntu install boots more slowly than my SUSE and Debian and Manjaro installs

I will reiterate here that this is not Firefox nor the snap backend causing this. There could be a number of possible explanations but we should probably split this off into a separate thread so that it doesn’t get confused with this topic if you felt the need to explore it further.

though did say many will be corrected post-release date for Ubuntu 22.04 LTS.

And here is one of the biggest benefits of snap packaging, the updates. Updates happen in the background without having to think about it. They are able to deliver all of the necessary libraries and dependencies alongside without impacting other packages too.

certain extensions like keypass and video download helper don’t work

Honestly this limitation is another benefit because it means that malicious extensions can’t get added too. Security confinement in a web browser is a direction that things need to go. Most bad stuff comes from the Internet and in general, the browser is the vehicle to deliver it. While not convenient, it is more secure. I’ll take security over convenience any day. As pointed out earlier by @KGIII extensions do work on the snap. I have Ublock and Bitwarden installed, both work as they do/did on the native package.

8 Likes

Update: I notice that the snap firefox now takes 7 seconds to launch. I think it is a big improvement from 15 seconds.

3 Likes

I hear that the Mozilla team ppa is not guaranteed to be maintained or not, so if you want nothing to do with snap, the tar.gz version is the best as it updates automatically and opens faster than either snap or flatpak.

2 Likes

Just to add a bit of trivia…

According to my dusty memory, PPAs were never guaranteed to be maintained. They’re really just for personal archives, but we’ve been using them in ways never intended. That was, again according to my dusty memory, one of the motivating factors to create Snaps in the first place.

6 Likes

@BasilCat Thanks for posting the how to install the non-snap Firefox.

I’ve now seen the light about Snaps not being a good choice on my old outdated junk box computers.

Thanks again.

I was going to post that the snap firefox is too slow to start (and I have an nvme ssd).
I think it was a mistake to go to snaps (the pros seem to be for developers and they are volunteers so …).
Thanks for the instructions.

EDIT:
I may stick with the snap (at least give me time to get used to it).
Why have shared libraries at all anymore?

Actually, there’s one very powerful pro that Snap gives to end users - improved security.

Programs are complex systems, and the computers they run on are even more complex. One somewhat annoying thing about computers is that, if you have the proper privileges, they do whatever you tell them to, no matter how ill-advised your command happens to be. As a result, it’s entirely possible for a program to accidentally butcher itself while you’re using it, causing all sorts of “interesting” problems. And because of how complicated computers are internally, developers actually make self-butchering code all too often, and then release it to the general public. Usually you have to do a very specific series of odd and tricky steps to get a program to really glitch out like this, but it’s doable.

Sometimes these bugs allow a user to modify the program’s executable code by feeding it wonky data, triggering the bug. If a user knows how the bug works in sufficient detail, they can put their own executable code into the wonky data, then feed the data to the program. The bug triggers, the code gets overwritten, and the program proceeds to execute whatever it was fed by the malicious user. This generally ends in a program crash (though not always), but it also results in arbitrary code being run from a chunk of data that shouldn’t have been executable.

And guess what Web browsers do? They download arbitrary data and perform a number of highly complicated and advanced operations on that data to get it to display a Web page on our screen. Say there’s an arbitrary code executing bug in the browser, and you load a Web page that happens to be designed to exploit that bug. Now whatever code the web page creator wants to be run on your system, gets run, without your permission. The possibilities at this point are generally endless - all the malicious web page maker has to do is make the executable snippet they give you download some application from a predefined location on the Internet and then run it.

Sounds like a perfect method of distributing malware? That’s because it is.

That means that if you don’t get a timely Web browser update, and you accidentally click on the wrong website during your Internet travels, it’s entirely possible that you just got hacked, and the malware now has access to everything in your system that’s user-readable.

Unless your browser is in a Snap package.

Once you Snap your browser, things change. Even if a malicious website sneaks some malware in your system through your browser, it doesn’t get full access to your whole system. Instead, it gets to stare at the mostly useless insides of a Snap container. Admittedly, it would be theoretically possible for a piece of malware to sneak through your browser AND break out of the Snap container, but it’s a lot trickier to break through both a browser and a container, since the malware now has to be prepped to crack through both. And if the Snap system doesn’t have any known vulnerabilities, it might be impossible for the malicious actor to break out of it.

In addition to the added difficulty of cracking through multiple layers of security, Snap is also designed to automatically update all your Snaps, pretty much whether you like it or not. Sounds crummy (and for some stuff it is), but it also keeps you more secure. An unsavvy user might think that, “Hey, I like my version of Firefox, leave me to it!”, and not realize that they just opened the door to get hacked to kingdom come. While forcing users to update generally doesn’t go over well with users, it does prevent malware from breaking into a system so easily.

Snaps may be rough around the edges and have some performance problems, but in a world where one security slip-up can spell disaster or near disaster, every little bit of extra security helps. Web browsers are extraordinarily complex, deal with arbitrary data from strangers on the Internet, and are one of the most commonly used programs on a computer - they’re a good target to strike at to hack a system, so it makes sense to apply seemingly overkill security to them.

(Note: If you have careful browsing habits and keep your browser updated all the time, it’s extremely unlikely that you’ll ever get hacked, especially if you use an adblocker. For attentive users, a non-Snapped browser should be just fine to use. Just be careful where you click if you go this route.)

5 Likes

In other words, snaps are basically sandboxed operating systems, right? And that also explains why you see a huge list of snaps as devices when you type lsblk in the terminal.

No, snaps are sandboxed containers. Snaps usually contain user applications. But there are also snaps that contain the kernel.

Snaps have some defined interfaces with the operating systems. The snap creator can define the defaults for the different interfaces.
For example, the Firefox snap is plugged to the camera interface (allows access to all cameras). But you can manually disconnect the Firefox snap from the camera interface.

5 Likes

@BasilCat
Thank you for your post. But I have a question. You write:

One thing i forgot to mention is that if you don’t use snaps at all, completely uninstall it with:
sudo apt remove snapd
and to prevent it from coming back apply: sudo apt-mark hold snapd.

Does that mean that instead of
sudo snap remove firefox
I do
sudo apt remove snapd
and then this:
sudo apt-mark hold snapd
, and then I start with “Download the tar from the website” and so on. Is that correct?
Thank you for an anwser in advance.

I don’t think that’s right. I’d do sudo snap remove firefox, then sudo apt remove snapd, then sudo apt-mark hold snapd.

2 Likes

I’ll add this here in case anyone is interested.

Awhile ago (April 2022) an article was posted in Planet Ubuntu on this topic…

You’ll note in the article, it covers pinning & even unattended-upgrades because it comes from a PPA. It’s also from Ubuntu developer Balint Reczey.

2 Likes