Browse Source

nmap

master
test2 5 years ago
parent
commit
3e25994837
  1. 58
      ex-1_iptables.adoc

58
ex-1_iptables.adoc

@ -101,15 +101,69 @@ See https://en.wikipedia.org/wiki/Nmap
== Find open Ports == Scan Ports
.Step 3 (find open ports) .Step 3 (find open ports)
=== Scan a Single Port, All Ports, or Series
[source,bash]
----
Nmap commands can be used to scan a single port or a series of ports:
----
=== Scan port 80 on the target system:
[source,bash]
----
nmap –p 80 172.21.0.3
----
=== Scan ports 1 through 200 on the target system:
[source,bash]
----
nmap –p 1-200 172.21.0.3
----
=== Scan (Fast) the most common ports:
[source,bash]
----
nmap –F 172.21.0.3
----
=== To scan all ports (1 – 65535):
[source,bash]
----
nmap –p– 172.21.0.3
----
=== Scan All TCP UDP Ports
Scan all UDP and TCP ports in a single command. We will use -sU for UDP and sT for TCP protocol.
[source,bash] [source,bash]
---- ----
nmap -sP 83.212.114.* nmap -sU -sT -p0-65535 IP
---- ----
.What Are Ports?
[NOTE]
====
On modern operating systems, ports are numbered addresses for network traffic. Different kinds of services use different ports by default.
For example, normal web traffic uses Port 80, while POP3 email uses Port 110. One of the ways that a firewall works is by allowing or restricting traffic over a particular port.
Because the ports into your computer can cause a security risk, it’s critical to know which ports are open and which are blocked.
====

Loading…
Cancel
Save