Step by Step Guide to Setup Lynis Security Audit Tool on Ubuntu 20.04 LTS

Lynis is a free & open-source security audit tool. It is installed by system administrators and security professionals to find the system vulnerabilities. It is easy to use & easy to scan the system. We can easily scan application patch management, file system, ports, Software malware, kernel vulnerability & etc.

There are few steps to install Lynis on ubuntu:

Step 1: Update the System.

apt-get update

Step 2: Check Available Lynis version provides by universe ubuntu 20.04  repo.

apt-cache policy lynis

  • Here is the command output.

Step 3: Install PGP key & Repo.

wget -O - https://packages.cisofy.com/keys/cisofy-software-public.key | sudo apt-key add -
echo "deb https://packages.cisofy.com/community/lynis/deb/ stable main" | sudo tee /etc/apt/sources.list.d/cisofy-lynis.list

  • Here is the command output.

Step 4: Install the required package.

apt-get install apt-transport-https

  • Update the package.

apt-get update

Step 5: Install Lynis on System.

apt-get install lynis

  • Check Lynis version.

lynis show version

  • Here is the command output.

  • Check Available version.

lynis update info

  • Here is the command output.

Step 6: Some Lynis Syntax.

lynis [scan mode] [other options]

  • To show commands.

lynis show commands

  • Here is the command output.

  • List the Lynis settings.

lynis show settings

  • Here is the command output.

  • List the audit profile.

lynis show profiles

  • Here is the command output.

Step 7: Audit the System.

lynis audit system

  • Here is the command output.

  • System tools & Boot-servcies info.

  • Kernel,Memory,Processes & unser info.

  • File system & USB devices info.

  • Ports,Networking & Printer info.

  • Software:firewall & web server info.

  • Databases & PHP info.
  • Lynis Secuirty scan details.

 

Leave a Reply