Using kali linux command line
Nmap Commands
-
nmap 192.168.1.0/24
- Description: This command scans all the hosts within the subnet
192.168.1.0/24
(which includes IP addresses from192.168.1.1
to192.168.1.254
) to discover live hosts and open ports. - Usage: Used for network discovery and auditing.
- Description: This command scans all the hosts within the subnet
-
nmap -sP 192.168.1.0/24
- Description: This command performs a ping scan on the subnet
192.168.1.0/24
to identify which hosts are up without performing a port scan. - Usage: Used for a quick check of which devices are online.
- Description: This command performs a ping scan on the subnet
-
nmap -O 192.168.1.7
- Description: This command performs OS detection on the host
192.168.1.7
. - Usage: Used to determine the operating system of the target host.
- Description: This command performs OS detection on the host
-
nmap -sV 192.168.1.7
- Description: This command scans the host
192.168.1.7
to detect service versions on open ports. - Usage: Used to gather detailed information about the services running on the host.
- Description: This command scans the host
-
nmap -O 192.168.1.5
- Description: Similar to
nmap -O 192.168.1.7
, this command performs OS detection on the host192.168.1.5
. - Usage: Used to determine the operating system of the target host.
- Description: Similar to
-
nmap -p 80 192.168.1.7
- Description: This command scans only port 80 on the host
192.168.1.7
. - Usage: Used to check the status of a specific port (in this case, the HTTP port).
- Description: This command scans only port 80 on the host
-
nmap -F 192.168.1.7
- Description: This command performs a fast scan on the host
192.168.1.7
, scanning fewer ports than the default scan. - Usage: Used for a quicker scan of the most common ports.
- Description: This command performs a fast scan on the host
-
nmap -f 192.168.1.7
- Description: This command performs a scan on the host
192.168.1.7
using fragmented packets. - Usage: Used to evade firewalls and intrusion detection systems (IDS).
- Description: This command performs a scan on the host
-
nmap 192.168.1.7
- Description: This command performs a default scan on the host
192.168.1.7
, discovering open ports and basic service information. - Usage: Used for a general-purpose scan of a single host.
- Description: This command performs a default scan on the host
Hping3 Command
hping3 --scan 1-65535 192.168.1.7 -S --rand-source
- Description: This command scans all ports (1-65535) on the host
192.168.1.7
using SYN packets, with random source IP addresses. - Usage: Used for comprehensive port scanning and to obscure the scan origin.
- Description: This command scans all ports (1-65535) on the host
Fping Command
fping 192.168.1.7
- Description: This command sends ICMP echo requests to the host
192.168.1.7
to check its availability. - Usage: Used for a quick ping check to see if the host is online.
- Description: This command sends ICMP echo requests to the host
WhatWeb Command
whatweb 192.168.1.7
- Description: This command scans the web server on
192.168.1.7
to identify technologies used (e.g., CMS, server software). - Usage: Used for web fingerprinting to gather information about the web technologies in use.
- Description: This command scans the web server on
Nikto Command
nikto -host 192.168.1.7
- Description: This command performs a vulnerability scan on the web server at
192.168.1.7
. - Usage: Used for web server security testing to identify potential vulnerabilities.
- Description: This command performs a vulnerability scan on the web server at
These commands are commonly used in network security and penetration testing to gather information about hosts and identify potential vulnerabilities.