News for hackers. Stuff that matters.
Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @12:30PM (#11187737)
What this could and should lead to is this: a separation between system packages and user applications, prefferably with two different managers.

What we have now are mostly system package managers, you want them to be stable, secure, having the latest features might not be necessary.

But we see more and more often that that distribution channel doesn't work well with applications: you end up with old, buggy, insecure applications because the distribution just couldn't keep up with the upstream update cycle. Why not have a cross-distribution application manager which distributes AppImages? That way, application distribution is an effort concentrated over all the distributions, possibly benefiting the entire community.

Re:AppImage: Linux apps that run anywhere by rythie on Saturday February 27, 2016 @02:18PM (#11188051)
Not everyone has root on their Linux box and even if you do, you ought to be able to install applications as you without sudo'ing anything. Right now most Linux applications guide you to a deb/rpm which runs as root (and who knows if you can trust it).

TBH this is just the start of making applications more secure, they ought to be sandboxed too, so one application can't read the data from another application by default (similar to how phones work).

Re:AppImage: Linux apps that run anywhere by jonotime on Saturday February 27, 2016 @03:27PM (#11188331)
There's also NIX, which I think does a good job of issolation in user space. https://nixos.org/nix/
Re:AppImage: Linux apps that run anywhere by jhasse on Saturday February 27, 2016 @07:09PM (#11189102)
Re:AppImage: Linux apps that run anywhere by michaelmrose on Saturday February 27, 2016 @09:54PM (#11189597)
You can make it slightly harder to infect the rest of the system leaving the factual truth that the moment you install malware you are hosed unchanged
Re:AppImage: Linux apps that run anywhere by chmike on Monday February 29, 2016 @03:50AM (#11194316)
Wouldn't this raise the issue of application updates ? If the app imports its own libraries, who will take care to update them if a security issue is detected ? That's the point to enforce using shared libraries on unix system.
Re:AppImage: Linux apps that run anywhere by michaelmrose on Saturday February 27, 2016 @06:12PM (#11188934)
You actually cannot make malicious applications safe you can however make nonmalicious applications inconvenient.
Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @02:22PM (#11188063)
I believe Ubuntu has done a some progress in this area with Snap packages.
Re:AppImage: Linux apps that run anywhere by riquito on Saturday February 27, 2016 @06:38PM (#11189008)
If you don't share common dependencies you're doomed to have security hazards.

Consider it this way: if you install package FOO with its dependencies A,B and C, and FOO's developer thinks it's "feature complete", the package will never be updated, but every time a vulnerability is disclosed in his dependencies you'll be it. For _every_ program maintained this way.

Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @08:17PM (#11189301)
My argument is that you'd have cross-distribution appimage maintainers who would press a button and rerun the build script with the new library if it's needed.
Re:AppImage: Linux apps that run anywhere by cben on Sunday March 06, 2016 @05:32PM (#11235896)
So appimage becomes yet another distro? (with the somewhat unique property that you can overlay it over other distros)
Re:AppImage: Linux apps that run anywhere by matzipan on Monday March 07, 2016 @07:20AM (#11238466)
More like app ecosystem.
Re:AppImage: Linux apps that run anywhere by michaelmrose on Saturday February 27, 2016 @01:27PM (#11187908)
I really think that although this might be a boon to packagers it results in an inferior system wherein people end up with bloated,buggy packages.

I don't want to deal with 2 different package managers and new users are apt to be confused by the idea that they get packages from 2 different places.

Re:AppImage: Linux apps that run anywhere by djsumdog on Saturday February 27, 2016 @01:46PM (#11187963)
Yea, I agree. I personally think that this is a huge step backwards.

Look at Android and MacOS. You have these self contained packaging things that contain all their dependencies. You have the same dependencies in each package. You have a TON of wasted space with packages that have the exact same built-in libraries and jar files.

Especially with Android, they could have made a real package dependency system, with slotted installs of all the jar/jar-versions from the official maven repos. When you install and app, it could install all its dependent jars. You'd still be able to do multiple versions of each of those jars, probably easier than it is with standard .so/.dll libraries.

Projects like this are a huge step backwards is terms of DRY principals and general package management.

Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @02:01PM (#11188012)
Is space really an issue in most non-mobile user devices nowadays? Consider the tradeoffs: a bit of space vs. packaging nightmare which results in old, buggy and insecure packages. This was posted a few days back on hn: https://statuscode.ch/2016/02/distribution-packages-consider...

I am not sure if the whole jar package dependency management would work under ART.

Re:AppImage: Linux apps that run anywhere by veddan on Saturday February 27, 2016 @03:36PM (#11188371)
I wastes memory too, having multiple copies of the same shared libraries loaded.
Re:AppImage: Linux apps that run anywhere by marcosdumay on Saturday February 27, 2016 @04:34PM (#11188627)
Memory spend on executables isn't a bottleneck even on mobile. You are getting into embedded territory for this to become an issue.
Re:AppImage: Linux apps that run anywhere by michaelmrose on Saturday February 27, 2016 @06:05PM (#11188907)
I really hate that people have this idea. It's why people create apps which consist of a built in web server their own copy of chrome that connects to said server.

In the end something that ought to have taken 10mb of space and 20mb of ram requires 100mb of space and half a gig of ram and still manages to be slow on a new system at operations that ought to have been fast on a ten year old machine.

Down with the Javascript generation.

Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @06:22PM (#11188967)
I've been spending a lot of time in the embedded area lately (sub-200Mhz 32k RAM automotive systems, firmware and fpgas) and I agree with you. But there's always tradeoffs. In this case you're trading some memory (which is cheap nowadays) for up-to-date, secure, usable apps, which seems to be a pretty complex thing to do. Nobody solved it so far. The people using node-webkit are offloading the library compatibility issues to the people who built Chromium and are provided with a consistent container to run their application in.
Re:AppImage: Linux apps that run anywhere by toyg on Saturday February 27, 2016 @09:36PM (#11189539)
Or in other words, they use a poor man's Java vm, except bigger and more fragile.
Re:AppImage: Linux apps that run anywhere by fredsir on Sunday February 28, 2016 @01:31AM (#11190101)
To be honest, chrome-"native"-packaged-webapps, or what you wanna call them, feels a whole lot better to use than any java based GUI app I have ever used, including JetBrains products.

I hate to use any of these chrome-"native"-packaged-webapp, though. I just hate java based GUI apps more.

Re:AppImage: Linux apps that run anywhere by khedoros on Saturday February 27, 2016 @06:58PM (#11189074)
The software that we build tends to gain layers. In theory, each layer adds new functionality that couldn't be done on a lower layer. The problem comes when someone unnecessarily implements lower functionality in an upper layer (like reading local files through a web server). It happens because systems are too complex now for a specific dev to know every layer, and new hardware is fast enough that it doesn't matter that you're taking an order of magnitude more resources than you actually need to do the task.
Re:AppImage: Linux apps that run anywhere by inopinatus on Saturday February 27, 2016 @08:17PM (#11189300)
Not so. This matters at scale too. Multiplied by ten thousand nodes, a 50MB wasted RSS becomes half a terabyte of unnecessarily procured silicon. I don't want to pay that tax.
Re:AppImage: Linux apps that run anywhere by takluyver on Saturday February 27, 2016 @03:42PM (#11188391)
Android and MacOS each have a lot more users than desktop Linux, a lot more applications packaged, and applications get updated in a more timely fashion. Obviously that's not all down to a difference in packaging, but it does seem like the inefficiency of duplicated dependencies isn't all that big a problem.

Android also runs on phones that still mostly have less storage and less RAM than our desktops, so you'd expect saving space to be even more important for Android.

Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @01:46PM (#11187961)
Well, it's the system that is composed of packages. The app images would be distributed through an app center. Most users wouldn't have to touch the system packages in their daily use case.
Re:AppImage: Linux apps that run anywhere by toyg on Saturday February 27, 2016 @05:57PM (#11188884)
> preferably with two different managers.

That's overcomplicating things. The "user" manager would have to figure out where the specific distribution is storing this or that lib. Doing it reliably across even a small subset of distributions (say, Ubuntu, Debian, Fedora and RedHat) and a small subset of their releases, would be very challenging.

It would make much more sense to add a "user mode" option for the likes of apt-get, whereby it does not need sudo and it will install the specified package in ~/bin, ~/usr etc, symlinking necessary libraries. That doesn't seem too hard to pull off, in theory.

Re:AppImage: Linux apps that run anywhere by pdonis on Saturday February 27, 2016 @07:41PM (#11189191)
> It would make much more sense to add a "user mode" option for the likes of apt-get, whereby it does not need sudo and it will install the specified package in ~/bin, ~/usr etc, symlinking necessary libraries.

And then any random piece of malware running in your browser can in principle hose all your applications. There's a very good reason that ordinary users do not have write access to application binaries on Linux.

Re:AppImage: Linux apps that run anywhere by zanny on Saturday February 27, 2016 @11:54PM (#11189918)
Any proposal of untrusted user level software installation will require, to be legitimate, a well implemented MAC solution to the program. Android actually demonstrates this fairly well using SELinux and app permissions.

New software could present its access requests to the user, to be approved or not. Unapproved or undocumented accesses are also displayed as notifications, where declining the running apps access becomes a permanent rule.

Of course, to standardize such a system across distros, either you need an abstraction layer access management syntax, or you have to get everyone to agree to one of SELinux / Grsec / Tomoyo / Apparmor.

Really though I think the obvious answer is that ten years from now we have something like xdg-app shipping generic usage filters and mandating userspace MAC on new programs, along with an xdg -> distro specific library mapping layer from something like appstream.

Re:AppImage: Linux apps that run anywhere by toyg on Saturday February 27, 2016 @09:32PM (#11189524)
It would hose only your "usermode" apps, which would be a small subset -- likely smaller unpopular apps that lag in the distro repository. The system as a whole would remain intact, so you can logoff and clean up the mess as root. What hack would rely on some specific app being deployed in user-mode anyway? To do what, steal user files it already has access to?

It's obvious that "usermode" should be the exception and not the norm, but from a security standpoint it's exactly the same as compiling and installing with custom prefixes.

Re:AppImage: Linux apps that run anywhere by pdonis on Saturday February 27, 2016 @09:47PM (#11189568)
> It would hose only your "usermode" apps, which would be a small subset

Until more and more user apps start to get out of sync with the "system" versions of things, and therefore need to be installed with the "user" option in order to work.

> What hack would rely on some specific app being deployed in user-mode anyway?

A hack that doesn't care about specific apps but just wants to compromise whatever it can. Like, you know, a virus.

> To do what, steal user files it already has access to?

And send them to the Internet, without your knowledge. Like viruses already do--only it's a lot harder to get them to run on Linux. At least, it is now.

Re:AppImage: Linux apps that run anywhere by nailer on Saturday February 27, 2016 @01:52PM (#11187982)
We use HTML5 clipboard and webcrypto and frequently get support requests from Linux users with outdated versions of supposedly 'evergreen' browsers.
Re:AppImage: Linux apps that run anywhere by vbernat on Saturday February 27, 2016 @12:39PM (#11187756)
That's hardly related to a package manager. You can for example run Debian unstable to get more up-to-date stuff or mix Debian Jessie with backports. Same package manager, different sources.
Re:AppImage: Linux apps that run anywhere by brbsix on Saturday February 27, 2016 @12:56PM (#11187820)
I think the whole point of OP is to have completely separate installs (e.g. system apps installed in one root and user apps in another). If you go installing latest apps from different sources/repos, you're bound to face conflicts with the system packages. E.g. while installing packages with CPAN or pip, it is really easy to cause conflicts with the system Perl or Python, respectively. Right now there are lots of varying solutions to address this such as virtualenvs and docker images. These are fine for developers, but generally not acceptable to consumers.

It would be nice to have a safe consistent experience, a generic user-mode package manager.

Re:AppImage: Linux apps that run anywhere by e12e on Sunday February 28, 2016 @02:38AM (#11190232)
FWIW, it's generally a bad idea to mix in testing and unstable in a stable system (or even just testing). My recommendation is to run stable along with backports (if needed) -- and use something like schroot[1] for running persistent (separate) sessions under testing, unstable etc.

Schroot essentially wraps up debootstrap and chroot along with mounting /proc etc, and (optionally) bind-mounting /home (which among other things gives access to x11 session cookies, for sharing one xorg display -- so one could run firefox, gimp or mplayr from an unstable-chroot on a stable system). Overall, with SSD prices dropping as sizes are increasing -- it might be better to simply use vms (one of the nice (potential) things about rkt -- the ability to run a "container" under kvm, turning it into a vm).

[1] https://wiki.debian.org/Schroot

Re:AppImage: Linux apps that run anywhere by matzipan on Saturday February 27, 2016 @12:49PM (#11187792)
What I'm suggesting is a decoupling between system package managers and application image managers (which should run across distributions/versions).

Edit: thinking about it, this should also be the perfect opportunity for a cross-distribution app store/center.

Re:AppImage: Linux apps that run anywhere by vanous on Saturday February 27, 2016 @01:54PM (#11187986)
Thanks for mentioning this. I have been running unstable for many years and when people ask I simply tell them that it's like running latest Ubuntu except i can stay with my favorite Debian.
Re:AppImage: Linux apps that run anywhere by hasenj on Saturday February 27, 2016 @04:47PM (#11188672)
Yea I never understood why there's no separation between these two. The fact that apt-get needs root password only makes sense if apt-get is meant for system packages.

User applications should not require root privileges to install.

Re:AppImage: Linux apps that run anywhere by michaelmrose on Saturday February 27, 2016 @06:10PM (#11188927)
Installers regularly install packages to system dir because it would be idiotic on a multi user system for each user to install different versions of Firefox to their home dir.

It also serves to keep unprivileged users from installing software.

You are free to install software to your home but it shouldn't be the default behavior

Re:AppImage: Linux apps that run anywhere by hasenj on Saturday February 27, 2016 @08:40PM (#11189357)
The overwhelming use case for desktop users is there's usually one user on the system.
Re:AppImage: Linux apps that run anywhere by michaelmrose on Saturday February 27, 2016 @10:04PM (#11189630)
Which is not a good reason to design anything based on that assumption it's extremely easy for a single user to use a multi user system but not the reverse.