Installation of Lynis on Arch Linux systems

Install Lynis on Arch Linux

Tutorial for Lynis installation on Arch Linux

Pacman

Arch Linux is getting more popular, due to its great community support and the way it is organized. Being a “rolling release” system, it is continuously up-to-date. Of course you want to make sure your security defenses are equally up-to-date, so that’s where Lynis comes in.

Normally pacman is used for installing new packages. Unfortunately, the lynis package does not show up.

[root@archlinux ~]# pacman -Ss lynis
[root@archlinux ~]# pacman -Ss rkhunter
community/rkhunter 1.4.2-1
    Checks machines for the presence of rootkits and other unwanted tools.

This is because the package is available in AUR, the Arch User Repository and not yet in the community repository. So we can use Yaourt to install Lynis from there.

Using Yaourt and AUR

Yaourt installation

In case you don’t have Yaourt installed, follow the two steps below.

Add to /etc/pacman.conf:

[archlinuxfr]
SigLevel = Never
Server = http://repo.archlinux.fr/$arch

Now install Yaourt:

pacman -Sy yaourt

Installation of Lynis

[user@archlinux ~]$ yaourt lynis
1 aur/lynis 1.6.2-2 (87)
    Security and system auditing tool to harden Unix/Linux systems
==> Enter n° of packages to be installed (ex: 1 2 3 or 1-3)
==> -------------------------------------------------------
==> 1

That’s it! Your package has been installed and it ready to use. Make sure to keeping your packages up to date on a regular basis.

yaourt -Syua

Voting

Screenshot of AUR website to vote for Lynis package.

Vote for Lynis package on AUR

We love to get Lynis into the community repository, so you can use pacman to install it and keep it up-to-date.

So if you like Lynis, log in at AUR and press the vote button.

With enough votes the package will be promoted to the mainstream software repositories, simplifying the installation even more.

Another option is using the aurvote package.

$ yaourt aurvote
1 archlinuxfr/aurvote 1.6-1
    Tool to vote for favorite AUR packages
2 aur/aurvote 1.6-1 (1239)
    Tool to vote for favorite AUR packages
3 aur/aurvote-git latest-2 (2)
    Vote for your favorite AUR packages (development version)
==> Enter n° of packages to be installed (ex: 1 2 3 or 1-3)
==> -------------------------------------------------------
==>

 

Lynis Enterprise

Lynis Enterprise screenshot to help with system hardening

This blog post is part of our Linux security series and the mission to get Linux and Unix-based systems more secure.

Does system hardening take a lot of time, or do you have any compliance in your company? Have a look at Lynis Enterprise.

Or start today with the open source security scanner Lynis (GitHub)


Leave a Reply

Your email address will not be published. Required fields are marked *