User Tools

Site Tools


nmap:nmap

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
nmap:nmap [2020/06/08 23:22] peternmap:nmap [2020/07/15 09:30] (current) – external edit 127.0.0.1
Line 1: Line 1:
 ====== NMAP ====== ====== NMAP ======
  
- 
-[[NMAP:NMAP|NMAP]] 
  
 ===== Nmap Target Selection ===== ===== Nmap Target Selection =====
Line 12: Line 10:
 |Scan targets from a text file|nmap -iL list-of-ips.txt| |Scan targets from a text file|nmap -iL list-of-ips.txt|
  
-These are all default scans, which will scan 1000 TCP ports. Host discovery will take place.+<WRAP info> 
 +These are all default scans, which will scan 1000 TCP ports. 
 + 
 +Host discovery will take place. 
 + 
 +</WRAP>
  
 ---- ----
  
-==== Nmap Port Selection ====+===== Nmap Port Selection =====
  
 |Scan a single Port|nmap -p 22 192.168.1.1| |Scan a single Port|nmap -p 22 192.168.1.1|
Line 25: Line 28:
 ---- ----
  
-=== Nmap Port Scan types === +===== Nmap Port Scan types =====
- +
-Privileged access is required to perform the default **SYN** scans.  If privileges are insufficient a TCP connect scan will be used.  A TCP connect requires a full TCP connection to be established and therefore is a slower scan.  Ignoring discovery is often required as many firewalls or hosts will not respond to **PING**, so could be missed unless you select the **-Pn** parameter.  Of course this can make scan times much longer as you could end up sending scan probes to hosts that are not there.+
  
 |Scan using TCP connect|nmap -sT 192.168.1.1| |Scan using TCP connect|nmap -sT 192.168.1.1|
Line 33: Line 34:
 |Scan UDP ports|nmap -sU -p 123,161,162 192.168.1.1| |Scan UDP ports|nmap -sU -p 123,161,162 192.168.1.1|
 |Scan selected ports - ignore discovery|nmap -Pn -F 192.168.1.1| |Scan selected ports - ignore discovery|nmap -Pn -F 192.168.1.1|
 +
 +
 +<WRAP info>
 +Privileged access is required to perform the default **SYN** scans.
 +
 +If privileges are insufficient a TCP connect scan will be used.
 +
 +A TCP connect requires a full TCP connection to be established and therefore is a slower scan.
 +
 +Ignoring discovery is often required as many firewalls or hosts will not respond to **PING**, so could be missed unless you select the **-Pn** parameter.
 +
 +Of course this can make scan times much longer as you could end up sending scan probes to hosts that are not there.
 +
 +</WRAP>
  
  
 ---- ----
  
-== Service and OS Detection ==+===== Service and OS Detection =====
  
 Service and OS detection rely on different methods to determine the operating system or service running on a particular port. Service and OS detection rely on different methods to determine the operating system or service running on a particular port.
Line 53: Line 68:
 ---- ----
  
-== Nmap Output Formats ==+===== Nmap Output Formats =====
  
 |Save default output to file|nmap -oN outputfile.txt 192.168.1.1| |Save default output to file|nmap -oN outputfile.txt 192.168.1.1|
Line 66: Line 81:
 ---- ----
  
-== Digging deeper with NSE Scripts ==+===== Digging deeper with NSE Scripts =====
  
 |Scan using default safe scripts|nmap -sV -sC 192.168.1.1| |Scan using default safe scripts|nmap -sV -sC 192.168.1.1|
Line 81: Line 96:
 ---- ----
  
-== Search for DDOS reflection UDP services ==+===== Search for DDOS reflection UDP services =====
  
 |Scan for UDP DDOS reflectors|nmap –sU –A –PN –n –pU:19,53,123,161 –script=ntp-monlist,dns-recursion,snmp-sysdescr 192.168.1.0/24| |Scan for UDP DDOS reflectors|nmap –sU –A –PN –n –pU:19,53,123,161 –script=ntp-monlist,dns-recursion,snmp-sysdescr 192.168.1.0/24|
Line 89: Line 104:
 ---- ----
  
-== HTTP Service Information ==+===== HTTP Service Information =====
  
 |Gather page titles from HTTP services|nmap --script=http-title 192.168.1.0/24| |Gather page titles from HTTP services|nmap --script=http-title 192.168.1.0/24|
Line 99: Line 114:
 ---- ----
  
-== Detect Heartbleed SSL Vulnerability ==+===== Detect Heartbleed SSL Vulnerability ======
  
 |Heartbleed Testing|nmap -sV -p 443 --script=ssl-heartbleed 192.168.1.0/24| |Heartbleed Testing|nmap -sV -p 443 --script=ssl-heartbleed 192.168.1.0/24|
Line 107: Line 122:
 ---- ----
  
-===== IP Address information =====+====== IP Address information ======
  
 Gather information related to the IP address and netblock owner of the IP address. Gather information related to the IP address and netblock owner of the IP address.
nmap/nmap.1591658570.txt.gz · Last modified: 2020/07/15 09:30 (external edit)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki