How To Install Nmap on Manjaro
In this tutorial, we will show you how to install Nmap on Manjaro. Nmap is a free and open-source network scanning tool that has become the go-to choice for network administrators, security experts, and ethical hackers. Its primary purpose is to discover devices and services running on a network, enabling you to map the network topology, identify potential vulnerabilities, and conduct security assessments.
This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo
‘ to the commands to get root privileges. I will show you the step-by-step installation of Nmap on a Manjaro Linux.
Prerequisites
- A server or desktop running one of the following operating systems: Manjaro, and other Arch-based distributions.
- It’s recommended that you use a fresh OS install to prevent any potential issues.
- SSH access to the server (or just open Terminal if you’re on a desktop).
- Ensure that your Manjaro system is connected to the internet. This is crucial as it allows you to download the required packages and the Nmap installation.
- A
non-root sudo user
or access to theroot user
. We recommend acting as anon-root sudo user
, however, as you can harm your system if you’re not careful when acting as the root.
Install Nmap on Manjaro
Step 1. Before diving into the Nmap installation, it’s crucial to make sure your Manjaro system is up to date. Open a terminal and execute the following commands:
sudo pacman -Syu sudo pacman -S base-devel
Step 2. Installing Nmap on Manjaro.
- Install Nmap Using Pacman (Official Manjaro Repositories)
Pacman is the default package manager for Manjaro Linux, and it simplifies software installation and management. To install Nmap using Pacman, execute the following command in your terminal:
sudo pacman -S nmap
This command tells Pacman to install the Nmap package along with any required dependencies. You’ll need to enter your password to authorize the installation.
Once the installation process is complete, you can confirm that Nmap is installed by running the following command:
nmap --version
This command will display information about the installed version of Nmap, confirming that the installation was successful.
- Installing Nmap from Source (Optional)
While the Pacman method is convenient and straightforward, there may be scenarios where you want to compile Nmap from the source. To begin the process, visit the official Nmap website and download the latest source code release. Save the downloaded file to a directory of your choice:
wget https://nmap.org/dist/nmap-7.94.tar.bz2
Now, it’s time to configure and compile Nmap. Follow these steps:
cd nmap-* ./configure make
-
- The
cd
command changes your current directory to the extracted Nmap source code directory. ./configure
checks your system for dependencies and configures the build process.make
compiles Nmap from the source code.
- The
After successfully compiling Nmap, you can install it using the following command:
sudo make install
Confirm that Nmap is installed by running the following command:
nmap --version
Step 3. Syntax Command Nmap.
Nmap is a versatile network scanning tool with various options and flags to customize scans according to your needs. Below is a table explaining the essential components of a Nmap command and examples to illustrate their usage:
Element | Explanation | Example |
---|---|---|
nmap |
The basic command to invoke Nmap. | nmap |
Target(s) | Specifies the target(s) to scan, which can be an IP address, hostname, or range. | 192.168.1.1 , example.com , 192.168.1.1-10 |
Scan Types | Nmap offers multiple scan types, each serving a specific purpose. | -sS (TCP SYN scan), -sU (UDP scan) |
Port Specification | Defines the ports to scan. You can specify single ports, and ranges, or use common port numbers. | 80 , 1-1024 , http,https |
Options and Flags | Various options and flags modify the scan behavior. These can include timing, verbosity, and output formats. | -T4 (timing template), -v (verbose output) |
Service and OS Detection | Nmap can identify services and operating systems running on target hosts. | -sV (service version detection), -O (OS detection) |
Output Specification | Specifies how the scan results should be formatted and where to save them. | -oA (output to all formats), -oN (output in normal format) |
Scripting Engine | Nmap has a scripting engine (NSE) for advanced scanning and automation tasks. | --script (run specific scripts) |
Congratulations! You have successfully installed Nmap. Thanks for using this tutorial to install the latest version of Nmap on the Manjaro system. For additional help or useful information, we recommend you check the official Nmap website.