Live data from Hacker News

Arch Linux AUR Repository Found to Contain Malware

sensorstechforum.com

71–80 of 137 posts

Re: Arch Linux AUR Repository Found to Contain Malware

#71
post #70

Is there a public database of linux malware found in the wild that one can study to know what kind of things to look for when reviewing PKGBUILDs and other open source code? EDIT: s/repository/public database/

Nothing that I know off. Are you thinking specific to Arch Linux or in general?

Re: Arch Linux AUR Repository Found to Contain Malware

#72
post #26

This is exactly what we've been preparing for. Don't use yaourt, and read those diffs. I know a lot of people don't do this, but it's important.

Even yaourt defaults to prompting you to read all the packages scripts and displays a red WARNING UNSAFE when the package is unmaintained as this one was.

It has options to configure it to do everything automatically, but you have to actively go in and set it so.

Re: Arch Linux AUR Repository Found to Contain Malware

#73

Earlier quoted context omitted.

What packages would you like to se inn our repositories?

Imho, especially things that are important solutions to common things on the Archwiki but are AUR, indicated with the AUR superscript there. For example for MTP: https://wiki.archlinux.org/index.php/Media_Transfer_Protocol The one that worked most stable for me was simple-mtpfs, but it's AUR. It happens with other archwiki topics too, I encounter it regularly though can't think of good examples from the top of my hea…

>simple-mtpfs

Not maintained (last commit in 2016). So that will be something low on the priority list.

>btrfs

The dedupe tool looks interesting. Noted on my todo.

>closure-compiler

Was dropped from the repository. Probably because of the lack of an maintainer.

Re: Arch Linux AUR Repository Found to Contain Malware

#74
post #70

Is there a public database of linux malware found in the wild that one can study to know what kind of things to look for when reviewing PKGBUILDs and other open source code? EDIT: s/repository/public database/

Nothing that I know off. Are you thinking specific to Arch Linux or in general?

In general, but also containing malware found in code belonging to the different distributions, like PKGBUILDs. I'm just thinking that part of the problem with the lack of review of AUR packages by the users is that it's not really obvious what one should be on the lookout for. What does linux malware found in the wild generally look like?, is what I'm wondering. I would think that it would benefit us all to make the cases where malware is found more easy to study.

The case shown here is pretty obvious looking, but I don't think it would be too difficult to make it better hidden. Seeing what kind of tricks are statistically more common would make PKGBUILDs easier to review.

Re: Arch Linux AUR Repository Found to Contain Malware

#75
post #4

From the article: "This is yet another incident that showcases that Linux users should not explicitly trust user-controlled repositories." LOL. Why should this only apply to Linux users? We should all be wary of downloading random things from websites. AUR has always been labeled "user submitted", but I guess it's easy to forget that some "users" are really out to cause harm.

Unofficial user repositories contain unofficial user software. Shockers!

Sarcasm aside, I think a lot of the pearl-clutching over this incident is down to people not understanding the difference between the official repositories and the AUR.

Re: Arch Linux AUR Repository Found to Contain Malware

#76

Earlier quoted context omitted.

Of course, one should be careful about what one installs on their system. Even more so an Arch user, which should be technical saavy in the first place. Anyways, I know I don't manually review everything I install on my system, I trust the packet manager. I'm not an Arch user so I don't know, but doest the AUR repo have some kind of code signing or automatic analysis of the packages?

No, AUR packages are PKGBUILD files, which are essentially little batch scripts that run inside a fakeroot. IMHO, the danger of a PKGBUILD itself doing something nasty is small--it would be limited to things like recording `uname -a`, listing all your installed packages: the things mentioned in the article. The real danger is that the PKGBUILD is installing some software, which you will later run with full user privi…

The PKBUILD runs in the fakeroot, but AFAIK the .install files (postinstall hooks etc) run on the host system directly, with root permission. Definitely something you will always want to review.

(Also, I don't really get the critique of tools like yaourt, since they make it easy to inspect the PKGBUILD and - if present - install files. The tool simplifies downloading, you still need to review yourself!)

Re: Arch Linux AUR Repository Found to Contain Malware

#77

Doesnt everyone know AUR packages are inherently unsafe? if you wanted to make sure they werent up to something you could read the pkgbuild

Given the design of most of the AUR "helpers" out there, I would guess that there are a non-trivial amount of users who view the AUR as safe.

Yaourt shows a big fat red warning every time you install a package. It also offers to open PKGBUILD and .install files for inspection.

Re: Arch Linux AUR Repository Found to Contain Malware

#78
post #55
post #15

Earlier quoted context omitted.

> yes, this is a fundamental problem with the security model of Arch Linux No, it's not. AUR is not Arch, and is not "supported" by Arch. It's a fundamental problem with the security model running code from randos on the internet. If someone published a git repo on GitHub that installed malware when you ran git clone git://github.com/user/repo . && ./configure && make && sudo make install you wouldn't be saying that…

I understand your point but the problem is that the title is "Arch Linux AUR Repository Found to Contain Malware" (and not, for example: "AUR Repository Found to Contain Malware"). I would argue that the implication (I guess reputation-wise if that matters) starts with the "Arch Linux" part. It's easy to jump on Arch because of this regardless of the fact that the AUR is not supported. At a cursory glance plenty of p…

This isn't unique to Linux.

Most people would read "Apple App Store Found to Contain Malware" as "Apple Devices Found to Contain Malware" too.

Re: Arch Linux AUR Repository Found to Contain Malware

#80
post #77

Earlier quoted context omitted.

Given the design of most of the AUR "helpers" out there, I would guess that there are a non-trivial amount of users who view the AUR as safe.

Yaourt shows a big fat red warning every time you install a package. It also offers to open PKGBUILD and .install files for inspection.

It should just show the PKGBUILD every time. If it's not doing anything sketchy it's often only a dozen lines.
Post reply on HN