::: spoiler Transcript Image of a man pointing a gun at his own foot.
Caption: Installing an AUR package without reading it's PKGBUILD. :::
::: spoiler Transcript Image of a man pointing a gun at his own foot.
Caption: Installing an AUR package without reading it's PKGBUILD. :::
69 Comments
NaibofTabr@infosec.pub · 128 pts · 2d
houndeyes@toast.ooo · 37 pts · 2d
Jesus_666@lemmy.world · 29 pts · 1d
If you want a bunch of stuff that's not in core or extra and you don't want to intensely babysit the AUR, you could try Chaotic-AUR. It hosts prebuilt packages for a bunch of AUR packages which are actively maintained by the Chaotic team.
I consider it to be more secure than the AUR proper since they actually care for their packages and review nontrivial changes. For instance, the recent takeover attacks didn't hit Chaotic-AUR builds since the changed packages didn't make it past the review.
It's still an unofficial third-party repository and closer to the AUR than to extra but I consider it a major step up.
Zachariah@lemmy.world · 14 pts · 1d
Yes, but is it good, neutral, or evil?
basxto@discuss.tchncs.de · 8 pts · 1d
it is arch
muusemuuse@sh.itjust.works · 4 pts · 1d
It is colorful socks
deathmetal27@lemmy.world · 3 pts · 1d
Yes
MonkderVierte@lemmy.zip · 1 pts · 1d
I don't think Arch is right for you.
JakoJakoJako13@piefed.social · 1 pts · 1d
IT'S MAHVEL BABY!
NotSteve_@lemmy.ca · 5 pts · 1d
I just recently reinstalled since I didn't feel comfortable with how many AUR packages I had and ive been using ChaoticAUR exclusively now. Can confirm that its a great repo
Azzu@leminal.space · 17 pts · 1d
I mean how often do you install AUR packages? Usually takes like a minute or so to skim through PKGbuild and the pkg comments and look for obvious issues. And most updates are just a sha hash and version change, taking like 5s to check.
HereIAm@lemmy.world · 12 pts · 1d
But wasn't the latest AUR attack from a dependancy in the pkgbuild? Going out of your way to review all the dependencies as well is not really possible by just skimming through the script.
basxto@discuss.tchncs.de · 6 pts · 1d
I need a better wrapper that shows me diffs since last build. I’m too lazy for this
Also pulling in release messages from git etc would be nice
devfuuu@lemmy.world · 6 pts · 1d
paru
NaibofTabr@infosec.pub · 1 pts · 1d
Rarely, to be sure. I tried Arch for a bit, but I need a computer that I can actually use to get shit done, that isn't a constant project itself. Even Qubes doesn't require as much effort to keep operational.
ElectroLisa@piefed.blahaj.zone · 74 pts · 1d
STABLE IS FOR HORSES I LOVE GAMBLING
/s
xthexder@l.sw0.com · 10 pts · 1d
I wish I could give you a second upvote, that's hilarious 😂
deathmetal27@lemmy.world · 4 pts · 1d
Well earned upvote, sir/ma'am.
call_me_xale@lemmy.zip · 36 pts · 2d
I usually do, but I don't really know what I should be looking for. What are some red flags?
akunohana@piefed.blahaj.zone · 44 pts · 2d
This video taught me a lot.
Check the list of dependencies. If you really want to vet the package, look through all of the dependencies listed and read their package descriptions on their source page (github, gitlab, codeberg, whathaveyou). Check also the URL, from which
makepkg(oryayor whatever) is going to pull some of the data. Is the URL legit?::: spoiler PKGBUILD of localsend
:::
Kangae_Hishiryo@scribe.disroot.org · 3 pts · 1d
Yeah. There's also some others behaviours to look at.
Like, does the PKGBUILD install the package on some non-standard location? That's a suspicious behaviour, although it's not an automatic red flag by itself.
Does it execute arbitrary code or any external script (worse if it's Python, Lua or JS)? That's a HUGE red flag in most of cases.
Does it (ab)uses of AWK, sed and the like? That's also suspicious in a variety of cases.
Malix@sopuli.xyz · 26 pts · 2d
as the other commenter said, but worth echoing:
Generally you should be aware of who'se software you're installing -> check if it's downloading the stuff from right place, and nothing extra. The PKGBUILD changes in the aur website are pretty good indicator if something has changed and how.
edit: npm itself, or it's usage isn't bad - but it is quite suspicious if the AUR package isn't for some webapp or so.
First_Thunder@lemmy.zip · 13 pts · 2d
Suddenly an npm command to some random package appearing in an update
dwt@feddit.org · 12 pts · 1d
I think that the whole concept of sharing user repos to install packages is sadly not really good anymore. Because now it suddenly exposes that there is usually neither a trust anchor to that repo, nor an established review and fix process for such things.
I‘d say, just use the community maintained official package sources for now.
realitaetsverlust@piefed.zip · 2 pts · 1d
I don't mean this in any mean way, but if you don't know what you should be looking for, you probably shouldn't install AUR packages. Just as I wouldn't recommend someone who has never climbed a mountain to try mt everest.
You need to be able to understand the build process before you install anything from the AUR. Everything else is the equivalent of installing random exe's you found on a forum on windows.
Luckily, there's a lot of different videos online regarding the AUR build process, and the archwiki has an excellent article aswell.
call_me_xale@lemmy.zip · 2 pts · 1d
To be clear, I have like... three? extremely popular AURs installed - I'm definitely not in the habit of grabbing random stuff.
lung@lemmy.world · -5 pts · 2d
Get AI to read it, it'll be 90% good enough
massive_bereavement@fedia.io · 6 pts · 1d
That might work until they realize people are doing it and then just add the right circumventions. After all I can test my exploit and see if Claude or Gemini can find it, and polish it until they don't.
xylol@leminal.space · 5 pts · 1d
Ask ai how to hide it from ai
merc@sh.itjust.works · 19 pts · 1d
its
deathmetal27@lemmy.world · 5 pts · 1d
My dumb ass
TechieDamien@lemmy.ml · 3 pts · 21h
What about your mute donkey?
deathmetal27@lemmy.world · 1 pts · 4h
I wrote "it's" instead of "its" in the meme.
Nalivai@lemmy.world · 15 pts · 1d
I'm running Arch daily since 2015, was on Debian before. I install and try a lot of stuff. Never had anything bad happened to me once. Worst case scenario the shit I just installed didn't work so I have to debug it.
Not endorsing this apparently dangerous lifestyle, but also a little bit maybe
Funkt4st1c@lemmy.world · 5 pts · 1d
Yeah same. Aur has been significantly less virus prone than the windows norm (inb4 wut abut winget >;ppp) of "Googling some shit you want and clicking the first website to roll the dice on predatory ads or malware or maybe the thing you wanted"
...not to mention if you have btrfs you can just rollback a month or two and call it a day.
deathmetal27@lemmy.world · 4 pts · 1d
This is more important after the recent news of malware on AUR
basxto@discuss.tchncs.de · 3 pts · 1d
Not updating AUR packages saved me from the last incedent 🙃I had 6 or sth packages installed who were in the list
cyberpunk007@lemmy.ca · 2 pts · 1d
I get why we need to do this but most people are not programmers either and probably don't understand wtf they're looking at.
While I understand some of what um looking at, when in just trying to get the updates over with its super annoying to review each aur pkgbuild.
richardisaguy@lemmy.world · 11 pts · 1d
Nah, if you really want to live on the bleeding edge you gotta make blindly installing vibecoded junk from shady parts of the AUR part of your workflow
zitrone@europe.pub · 10 pts · 1d
just use nix instead
we have super secure mechanisms in place to prevent supply chain attacks
/s (nix just hasn't been targeted yet (as far as we know 💀💀))
Euphoma@lemmy.ml · 4 pts · 1d
Yeah, I just update all 20 flakes that I sourced from github and pray that none of them were hacked
corsicanguppy@lemmy.ca · 4 pts · 1d
Maslow, is this your hammer?
chortle_tortle@mander.xyz · 3 pts · 1d
Isn't the real security through obscurity just being such a fringe market no one bothers? 🤔
MonkderVierte@lemmy.zip · 9 pts · 1d
All pointing with fingers to AUR, but the issue was (yet again) with NPM.
chortle_tortle@mander.xyz · 4 pts · 1d
Sorry I missed something, how so?
MonkderVierte@lemmy.zip · 6 pts · 1d
The compromised packages load a script from thr net that runs a compromised npm package ("atomic-lockfile" 1.4.2).
Ok, also a AUR issue. But more so a NPM one, since they have all full moon two supply-chain attacks.
MalReynolds@slrpnk.net · 7 pts · 1d
If possible do it in a distrobox and down networking before running, yes that won't stop the curl | sh in the install, but at least you can blow it away without hurting your main install and it will likely infect only the distrobox. Bonus points for an immutable main OS.
As the whole supply chain attack vector gets more sophisticated, and probably subtler in effect, these are going to be harder and harder to spot and likely start making it into main repos. Keep sharp people.
Not real fun for a linuxmemes post, but I think it needs saying.
Neptr@lemmy.blahaj.zone · 6 pts · 1d
Distrobox is not an isolated environment, it is quite the opposite. They say so themselves on their page:
I would argue that Docker isn't a good way to stop malware either, since it is highly vulnerable to sandbox escape leveraging the shared host-guest kernel, like the many of LPEs that have been found in the last few months (example using copy-fail).
Docker is not a secure sandbox, Podman is not a secure sandbox, Flatpak is not a secure sandbox. Use a VM, or better yet, don't use the AUR.
MalReynolds@slrpnk.net · 1 pts · 1d
True, you'll note I didn't say it is sandboxed or isolated, but it is a different environment. Paths that point to normal things like /usr etc. will be in the distrobox environment. That said, unless you use a custom home for the distrobox (you should anyway), your home directory is hosed. At this point I expect the malware to not be distrobox aware and use things like distrobox-host-exec, that may change.
A VM is absolutely a better approach, if significantly more frictional.
Neptr@lemmy.blahaj.zone · 2 pts · 1d
You don't need to say the words "sandboxed" or "isolated" to say effectively the same thing. Your goal with distrobox was to keep the AUR malware separate from your normal system, no?
Security through obscurity is not security. The malware can do the same data exfiltration regardless of root access because the AUR malware has been about stealing secrets in user-readable directories. Setting a custom home for distrobox does not disallow access to the normal one.
Say for example that your default user home is /home/user and you set the distrobox home to /tmp/home
If you run
ls $HOMEinside distrobox it will list files in /tmp/home, but just as easily you could runls /home/$USERand it would list in your default home. Or alternatively just use the find command and steal secrets without targeting the user home.This is because changing the user home through distrobox doesn't do anything about preventing directory traversal to your default home.
If your goal is to create a different environment and you don't care that it won't stop malware, use Incus or Podman directly. Distrobox is the wrong choice.
My point was simple: when dealing with malware, distrobox is not an effective method of creating a "different environment" because that is antithetical to its stated goals.
You can do whatever you want, I am not here to police your choice on your personal system. I only take issue with recommending this strategy to others.
QuadratureSurfer@piefed.social · 1 pts · 1d
Would Firejail fall for the same/similar sandbox vulnerabilities that Docker containers do?
Neptr@lemmy.blahaj.zone · 2 pts · 20h
Things sandboxed by Firejail share the same host kernel. Therefore, kernel vulnerabilities could allow for privilege escalation.
Firejail itself is a security-hole. It is a massive root SetUID binary which can and has been used for privilege escalation. I avoid it entirely. Unprivileged sandboxes are better, but lack the built-in profiles provided by Firejail.
If I was trying to sandbox malware, I would use sydbox. It is memory safe (unlike Firejail or Bubblewrap), unprivileged (unlike Firejail), secure sandbox by default (unlike Bubblewrap), extensively uses all relevant Linux security features/modules (more than any other), and actually helps to stop LPE by re-implementing or denying dangerous syscalls like in the case of many of the recent vulnerabilities. Biggest caveat is that it's not for beginners, even though it abstracts a lot of the complexity. I'd also neverbrun malware in just a sandbox, but use that alongside a proper VM.
TL;DR No sandbox will save you from good malware. Firejail might be enough for script kiddies, but could make your system more vulnerable to privilege escalation attacks. Avoid installing things you don't need.
MonkderVierte@lemmy.zip · 2 pts · 1d
Btw, login uses /bin/sh (or respective), script headers also, all fixed paths; would anything break, if you do
alias sh=echoin your session setup script?Sivecano@lemmy.dbzer0.com · 6 pts · 1d
Someone put my WM on the AUR. I am thus proud to be authoring malware :)
KernelTale@programming.dev · 6 pts · 1d
If it's endorsed by the project team I might as well. At that point it's the same as downloading from GitHub and if I am in AUR I've probably not found it in standard repos nor flathub.
RustyNova@lemmy.world · 6 pts · 2d
I don't even read the nix files I install from lol
OR3X@lemmy.world · 5 pts · 1d
AUR Arch UrGettingMalware Repository
wilmo@programming.dev · 4 pts · 1d
I use Arch without touching this AUR in my latest install. Just use what's in the main package repos or flathub
unknownman@lemmy.zip · 2 pts · 21h
I use arch just to be able to use AUR lol
prole@lemmy.blahaj.zone · 1 pts · 20h
You can just make an Arch distrobox to access the AUR
MonkderVierte@lemmy.zip · 3 pts · 1d
Update your desktop only all one or two weeks, get basic protection (adblocker, hosts file), read the news.
It's a peaceful life.
corsicanguppy@lemmy.ca · 3 pts · 1d
I didn't know it was.
Kangae_Hishiryo@scribe.disroot.org · 3 pts · 1d
I once found a Rust program that streamlined the PKGBUILD reviewing process a lot by, first of all, giving you a really neat list of patterns and behaviours that would make a PKGBUILD suspicios or even plain dangerous, then having a scriptable rule-based engine that would either abort that operation, or show warns and workarounds to you.
I forgot its name, unfortunately, and I installed it on my previous installation (Garuda, now I'm on CachyOS).
Very dumb of my part not to try to write that down before the OS change lol.
UncleReaton@lemmy.ml · 3 pts · 1d
pkgwatch maybe?
Kangae_Hishiryo@scribe.disroot.org · 2 pts · 1d
It was not that one, but yeah, it's basically the same.
I just remembered the one(s) I used a while ago, tho, they were aur-guard, and aur-scanner, I used these two (the second one just because its
aur-scan codes [OPTIONS]andaur-scan explain <CODE>commands.Solrac@lemmy.world · 2 pts · 1d
I was contemplating moving to NixOS, but then another fiasco just happened, masse me question what would one have to lose by switching to Qubes instead, considering the increasingly surveiling internet.
sel@piefed.social · 1 pts · 1d
I just don’t understand the process of I don’t have two minutes to read what I’m installing. It’s fucking batshit crazy that all these retards want to come use Linux which is fine but then when they get solid advice they tell us they can’t be bothered.
flying_sheep@lemmy.ml · 3 pts · 1d
Yeah, when something isn't in the official repos, NixOS exists, Flatpak exists, and they're all vetted.
Wanting a super clean system where everything is managed by pacman is purely about taste, so if you want it, you clearly can be bothered to put in the 2 minutes of work.
bennypr0fane@discuss.tchncs.de · -3 pts · 1d
Without reading its PKGBUILDfixed it for you. The AUR is toast, we have to say goodbye to it now.