4 ms·
Developers: Let distros do their job
- Seirdy 5y agoI generally agree with this article, with three exceptions: 1. It's helpful to distribute a statically-linked binary for users of distros that don't yet have packages. 2. It's also useful for situations in which distro packagers will want to make suboptimal packages. For instance, pretty much every single Linux and BSD distro builds chromium with varying levels of weakened security; some disable CFI and others use unsupported toolchains without the right hardening features. In the context of software that needs to be built with strict toolchain hardening and rapid updates, it can be quite useful to use "official" builds that check those boxes. 3. Reproducible builds: developers are in a good position to ensure their software works well in a reproducible pipeline. The best way to do this is to build reproducible binaries themselves. Once they have such a pipeline set up, they should make binaries (or at least checksums) available so others can try to reproduce those builds or report bugs if they can't. This is a good example of a situation where the line between "developer" and "packager" gets really blurry. These three reasons have overlap. A reproducible build with maximum compiler hardening flags can provide assurance of the package's security; if a distro maintainer finds that enabling those flags causes a crash, they can compare against the reproducible build to better understand the issue. Beyond these three reasons, packaging is best left up to a distribution.
- esarbe 5y agoIt's not working. So many distros are missing out on any number of packages because there is not enough manpower to package all the various software in an arbitrary number of ways. That's why many projects gave up on packaging software altogether - if they can away with it - and just do the `curl|sh` trick. And this one is dangerous and an a recipe for inexperienced users to shoot their system. Flatpak - contrary to the single dismissive like the author threw at it - is actually the proper way to package non-essential user software. It is toolchain agnostic, offers reproducible builds in a reproducible pipeline, offers a whole set of hardening features, is sandboxed, vendor independent and offers backward compatibility as well as a mechanism for upgrades. What's not to like?
- necovek 5y agoThe fact that a security issue (or even a bug) in one of your deps that you bundle means a rebuild. But you might not even know you need it, whereas someone else has it fixed because it causes, eg. subtle data corruption. The fact that even Flatpak/Snaps have "frameworks" tells you that it's not exactly what it pretends to be. Other than sandboxing, you could have had all that with static binaries forever, and, yet, it was seldom done. I think dependency management and sandboxing are two separate issues: I dislike dep management of Snap/Flatpak, but I like their sandboxing approach (ofc, practically, there's still a long way to go).
- esarbe 5y agoSlight correction; updates in the base image don't need a rebuild, so everything that you don't specifically add to the Flatpak can be upgraded independently of your application. Otherwise; yes. It's a new package that depends on a new version of a library, so this is going to take a rebuild. That requires software developers to mind their dependencies and update as required. But that's already the case if you are using a dependency that's not provided as a separate package by your distribution. And seeing the huge library of Python and Perl and Node dependencies that do not get packaged by the distributions, this seems to be a quite common case. > But you might not even know you need it, whereas someone else has it fixed because it causes, eg. subtle data corruption. I think if you are developing a software and a library dependency causes subtle data corruption, you should take explicit action and update the library dependencies, instead of relying on the distribution to "silently" ship an patched version of the same release of the library. > I think dependency management and sandboxing are two separate issues: They are, agreed. > I dislike dep management of Snap/Flatpak, Other than the base images, there is no dependency management for Flatpak. Dependency management happens not at installation but at build time using the dependency management provided by the build system.
- necovek 5y ago>> But you might not even know... > I think if you are developing a software and a library dependency causes subtle data corruption, you should take explicit action I think that's obvious, which is why highlighted that you might be unaware of the problem: it's something you get for free with shared dependencies. Basically, if you rely on a distribution with commitment to keep packages secure for a long time (like Ubuntu LTS main packages), that removes a lot of work for you: basically, work is shared between people, and you get to enjoy the benefits. > Dependency management happens not at installation but at build time using the dependency management provided by the build system. We seem to be saying the same thing: dependency management at build time is what I dislike because you don't get that burden shared.
- necovek 5y agoUnfortunately, I think people who think the same are in a minority. And some distros are also attempting to shy away from the responsibility (first few Ubuntu LTSes had a huge catalogue of python libraries in "main", which meant that they had 5 years of security fixes while keeping backwards compat guaranteed). I seriously believe there is a business opportunity for people to manage security of others' dependencies (backport patches and push backward compatible fixes). Higher levels could even get security audits as part of their package.
- AnIdiotOnTheNet 5y agoI couldn't disagree with Drew more on this. It is ridiculous to rely on unpaid third parties to get your software distributed. I can't count the number of times I've wanted to install software that isn't in the repo, or is a horrifically out of date version. You know what is more important than software that's perfectly secure? Software that you can actually use. > You can take advantage of all of this innovation and research for the low price of zero dollars by standing back and letting distros handle the distribution of your software. If someone packages your software, if they don't change anything, and if they keep it up to date. All three frequently fail to happen. What do you expect for free?