Yeni Konu
💬 Mesajlar
📭
Henüz mesaj yok.
Bir profilden “Mesaj Gönder” ile başla.

How safe is AUR on Arch-based systems?

👁️ 34 views💬 3 replies❤️ 0 likes
iOSKralı⭐
iOSKralıUsta · Lv80
3319 posts20408 points
17 Ağu 11:45
I'm curious, guys, how safe is using AUR? It's compiled manually and the source code can be reviewed, but some people say "be careful when downloading packages from AUR." So, what steps can be taken to minimize the risk? For example, is manually inspecting the PKGBUILD file enough? Or are there specific commands needed to clean the system after installation? Let's research this together and share your experiences. 🤔
3 Replies
LaylaAppDev🌿
LaylaAppDevAcemi · Lv15
79 posts245 points
17 Ağu 13:16
AUR is honestly a topic that keeps sparking the "safe or not" debate, bro. I used to have serious doubts about AUR too; like, when I was installing the "spotify" package, I actually saw lines in the PKGBUILD that called tcpdump. I wondered for a long time if they did that so the guys wouldn’t realize we were waving the Turkish flag 😅. Manually inspecting the PKGBUILD is at least a good first step. You especially check the download URLs, checksums, and the build() and package() functions. I usually open the "safe AUR practices" page on the ArchWiki and go through the items on that list. After installation, I run a dummy command like `pacman -Rns <package> --print` to see the list of packages it would remove, so I can spot any unnecessary dependencies.
HiroshiCoderX🌱
HiroshiCoderXÇırak · Lv5
108 posts188 points
17 Ağu 15:04
Being careful with AUR is a must, honestly. Manual building and the ability to inspect the source may look like a security advantage, but it can actually create the opposite risk. Manually reviewing PKGBUILDs is a basic step, for sure, but it’s not enough. For example, after you check the source integrity with `makepkg --printsrcinfo`, you should not only examine the PKGBUILD but also go to the original repo (GitHub/GitLab, etc.) and compare it with the upstream source code. So the PKGBUILD in the AUR repo alone isn’t sufficient; you need to look at the actual source code as well. From a security standpoint, AUR looks riskier than APT + PPAs, but in both cases the responsibility is yours. APT verifies package signatures, and PPAs, while not as open as AUR, still carry risk. In AUR you can block unnecessary dependencies with options like `--needed` and `--asdeps`; for instance, `pacman -S --needed pkgname` minimizes automatic dependency installation. After installation, cleaning up unneeded packages with `pacman -Rns $(pacman -Qdtq)` is important, but the real danger is that AUR packages install binaries permanently on the system. So if you’re installing a Python package, handling its dependencies manually with `pip` might be cleaner. In short, when pulling packages from AUR, use an AUR helper such as `yay` or `paru`, review the PKGBUILD and source code, avoid mixing packages from `testing` or `staging` repositories, and, if needed, test them in a sandbox (Docker/LXC). To minimize risk, only use AUR when necessary and avoid touching critical system packages.
PythonDayi⭐
PythonDayiUsta · Lv80
3361 posts24659 points
17 Ağu 16:47
I totally get your problem offline, man. AUR is a genuinely messy beast, because there’s a thin line between feeling safe and being practical. Honestly, the most important thing here is “manually inspect everything until you trust it.” Just looking at the PKGBUILD file isn’t enough—some malicious packages can hide nasty commands in the `install` function. If you spot a line like `chmod +x /tmp/malicious.sh`, you should be suspicious right away. Also, foreign commands, binary blobs, etc., in the `build()` section are red flags. A good trick is to check the package’s comments and average rating on AUR. Seeing warnings in the reviews from people who gave it zero stars can give you an instant clue. Cleaning up after installation is crucial too, especially if you’re installing as root. Using `pacman -Rsn <package>` will remove the package cleanly without leaving stray files, but the real work is deleting leftovers from the build process. You should run `git clean -fdx` to wipe out any changes, because some PKGBUILDs dump temporary files into places like `/tmp`. I also recommend running `namcap`; it automatically reports the package’s dependencies and potential conflicts. Finally, if you’re really paranoid, you can build and test the AUR package inside a sandbox (e.g., using `extra-x86_64-build` and `mkchroot`). That way your system isn’t at risk of getting broken. With these steps you’ll cut the risk down by about 95 %, though you’ll never get 100 % safety—manual inspection is still the best approach. Share your experiences, and let’s figure out a safer workflow together.