WEBVTT

00:07.120 --> 00:11.980
Hello, guys, and welcome to
another video of this chapter.

00:12.010 --> 00:14.160
This video will help you understand TCP

00:14.190 --> 00:19.260
SYN Flood Attacks otherwise known
as denial of service attack.

00:19.290 --> 00:24.220
So you have to perform one
using Kali Linux and it's been three

00:24.240 --> 00:28.900
and correctly identified
one using the Wireshark protocol

00:28.920 --> 00:33.120
for some information regarding denial of
service attacks in general, there are

00:33.140 --> 00:38.380
simple to carry out and it
can cause serious damage.

00:38.410 --> 00:41.220
And they are and always of this

00:41.250 --> 00:45.320
in a SYN flood Attack
and malicious party Exploit the TCP

00:45.350 --> 00:51.260
protocol three way handshake to quickly
cause service and network disruptions,

00:51.290 --> 00:54.700
ultimately leading to a
denial of service attack.

00:54.730 --> 00:57.120
These types of attacks can easily take

00:57.150 --> 01:01.980
admin's by surprise and can
become challenging to identify.

01:02.010 --> 01:05.240
Likely DOS like Wireshark makes it an easy

01:05.270 --> 01:10.050
process to capture and verify any
suspicions of a denial of service attack.

01:10.080 --> 01:13.260
So how a TCP SYN Flood Attack work.

01:13.290 --> 01:17.930
So let's go and explore how a
TCP SYN Flood Attack works.

01:17.960 --> 01:22.980
So when a client attempts to connect to a
Server using the TCP protocol,

01:23.010 --> 01:28.920
for example, HTTP or HTTPs
it is first required to perform a three

01:28.950 --> 01:35.260
way handshake before any data starts to be
exchanged between the two

01:35.290 --> 01:39.560
since, the three way TCP handsyn
is always initiated by a client.

01:39.590 --> 01:43.180
It sends a Syn packet to the Server.

01:43.210 --> 01:46.760
The Server next replies,
acknowledging the request and at the same

01:46.790 --> 01:54.060
time it sends its own SYN
request with the SYN-ACK packet.

01:54.090 --> 01:56.200
Then finally, the client sense and

01:56.230 --> 02:02.380
acknowledge packet, which confirms both
two hosts agreed to create a connection.

02:02.410 --> 02:04.640
The connection is therefore established

02:04.670 --> 02:09.450
and they can be
transferred between these two.

02:09.480 --> 02:11.580
In a SYN Flood Attack

02:11.610 --> 02:16.240
the attacker sends a high volume of SYN
packet to the Server using Spoofed IP

02:16.270 --> 02:20.610
addresses, causing the
Server to send a reply.

02:20.640 --> 02:21.960
SYN-ACK.

02:22.800 --> 02:25.480
In this case, as we said earlier, and live

02:25.510 --> 02:30.040
exports half open are waiting for a reply
from the host that basically doesn't

02:30.070 --> 02:33.340
exist, as you can see
from the picture here.

02:33.370 --> 02:37.660
So in a simpler, more direct Attack
without IP Spoofing

02:37.690 --> 02:42.040
by flooding, the target was seen packets
and not responding.

02:42.680 --> 02:46.680
With acknowledgement, and I think you can
easily overwhelm the target resources in

02:46.710 --> 02:53.000
this state, the target struggles to handle
traffic, which in turn will increase CPU

02:53.030 --> 02:58.880
users and memory consumption, ultimately
leading to the exhaustion.

02:59.000 --> 03:01.880
Of its resources, CPU and RAM.

03:02.120 --> 03:07.040
At this point, the Server will no longer
be able to serve legitimate client request

03:07.070 --> 03:11.540
and ultimately lead to
a denial of service.

03:11.570 --> 03:14.880
So let's just go ahead and perform a TCP

03:14.910 --> 03:19.520
SYN Flood Attack
in Kali Linux with hping3.

03:19.640 --> 03:21.880
And at the same time, we're going to

03:21.910 --> 03:27.280
locate Wireshark
at the target machine so we can see and

03:27.310 --> 03:31.980
identify and capture
the denial of service attack.

03:32.000 --> 03:33.880
So the simplest way to perform such an

03:33.910 --> 03:39.980
attack is via Kali Linux machine
and more especially with the hping3,

03:40.010 --> 03:45.820
a popular TCP Penetration Testing Tool
usually including Kali Linux.

03:45.850 --> 03:48.560
If you don't have a hping3 in your Kali

03:48.590 --> 03:53.700
Linux distribution, you can
just go ahead and install it.

03:53.730 --> 03:58.480
Using apt does get install hping3.

03:59.200 --> 04:01.200
So in this machine.

04:01.240 --> 04:04.040
I have already installed hping3.

04:05.840 --> 04:11.600
So I don't need to install it
in most of the cases, attackers will use

04:11.630 --> 04:17.060
hping or another tool to spoof
random IP addresses.

04:17.090 --> 04:21.100
So that's what we are going to focus on.

04:21.130 --> 04:23.380
So I'm not.

04:23.400 --> 04:25.100
Going to type the command, the full

04:25.130 --> 04:29.460
command that we're going
to use, I have it.

04:29.480 --> 04:36.820
I have it here, but I am going to explain
in detail what this command includes.

04:36.840 --> 04:39.860
So let's explain in detail.

04:39.890 --> 04:43.000
We are setting one thousand five hundred

04:43.030 --> 04:48.820
packets at the size of
one hundred twenty Bytes each.

04:48.840 --> 04:51.980
We are specifying the SYN, Flug.

04:52.010 --> 04:54.540
That IT should be enabled.

04:54.570 --> 04:58.220
With TCP window of 64

04:58.250 --> 05:05.220
to directly, Attack, to our victim, to
HTTP, Web, Server, we specify the port.

05:05.250 --> 05:12.140
In this case, which is eighty for HTTP
and used to flood the flood fog

05:12.160 --> 05:17.180
and use the flood flag
to send packets as fast as possible.

05:17.210 --> 05:22.680
As you would expect, the -- run
dust the source flag

05:24.000 --> 05:29.800
generates spoofed IP addresses to disguise
the real source and avoid detection, but

05:29.830 --> 05:37.220
at the same time, stop the victims SYN-ACK
reply packets from reaching the target.

05:37.250 --> 05:39.920
So this IP that I have here, the command

05:39.950 --> 05:46.500
is the my windows look on machine
IP address, which is not Server.

05:46.530 --> 05:51.880
We are going to perform this attack on my
local Windows machine and you will see

05:51.910 --> 05:57.180
that it is able to capture such
an attack using Wireshark.

05:57.210 --> 06:02.140
Before you press enter on this command,
you need to be able to go

06:02.170 --> 06:07.640
to the Windows machine and open
wireshark, so let just go ahead and do

06:07.670 --> 06:11.400
that first,
so you go to your Windows machine and you

06:11.420 --> 06:17.680
open the Wireshark and you choose the
network opt here you would like to capture

06:17.710 --> 06:23.860
the packet from this case is my Wi-fi
and start capturing.

06:23.890 --> 06:29.120
So now we start capturing the traffic on

06:29.150 --> 06:34.440
the Windows machine and we're going to go
straight away to our Kali Linux machine to

06:34.470 --> 06:38.980
perform the DDOS Attack and then come back
to Windows Machine to see how the

06:39.010 --> 06:43.540
SYN Flood Attack is being
captured by the Wireshark.

06:43.570 --> 06:48.200
So we are in our Kali Linux machine ready
to press under to perform the Attack.

06:48.230 --> 06:50.440
So we just going to have.

06:50.640 --> 06:52.080
So we just going to go ahead and

06:52.100 --> 07:00.600
press enter and see that the command
is already running and creating.

07:00.640 --> 07:03.100
The SYN Flood Mode.

07:03.130 --> 07:06.520
Let's go now to Windows Machine and see if

07:06.540 --> 07:12.600
our shark is detecting the SYN F
lood Attack.

07:14.920 --> 07:18.720
So now we are on this machine,
and as you can see, there is a lot of SYN

07:18.750 --> 07:23.240
packages coming in our
machine continuously.

07:24.640 --> 07:28.560
From BIOS IP addresses, as we said.

07:30.360 --> 07:33.900
All Directory to our windows machine.

07:33.920 --> 07:36.660
And they keep coming
and coming and coming.

07:36.690 --> 07:40.840
This, of course, raises CPU consumption.

07:41.640 --> 07:44.400
You can go ahead and see that when you

07:44.420 --> 07:49.880
open task manager, in your windows machine
checking the performance.

07:50.200 --> 07:53.220
And take the CPU consumption,

07:53.250 --> 07:58.860
so the SYN, the TCP SYN Flood Attack
continuous right now, we can see like.

07:58.890 --> 08:03.360
Wireshark is capturing that, so let's go
ahead to our Kali Linux machine, stop the

08:03.390 --> 08:08.960
SYN Flood Attack and then immediately
return to our windows machine and stop the

08:08.980 --> 08:12.680
capturing and go ahead
and check a little bit.

08:12.710 --> 08:15.160
The SYN Flood Attack.

08:16.160 --> 08:21.560
So you can stop this Attack by pressing
Clt X to your Kali Linux machine.

08:22.240 --> 08:23.800
So you can stop the Attack by pressing

08:23.830 --> 08:28.600
until see,
and you can see that the Attack has

08:28.630 --> 08:34.560
stopped, so let us go back to our window
machine and stop the capturing Wireshark.

08:37.160 --> 08:41.760
So now we are back to our
Windows machine, and as you can see, we

08:41.790 --> 08:47.260
stopped the capture
of the network traffic and.

08:47.290 --> 08:51.480
We can start, like, investigating the
whole thing from the beginning, and you

08:51.510 --> 08:56.780
can see that when we started capturing
the package, there's stuff going on.

08:56.810 --> 09:01.260
And if you go further.

09:01.290 --> 09:06.640
You can see that the Attack will start at
some point and Wireshark is

09:06.880 --> 09:11.740
capturing that,
so the moment you see a lot of

09:11.770 --> 09:18.560
SYN Flood attacks on the port ID,
you will see that the attack start.

09:23.440 --> 09:25.120
So here.

09:26.120 --> 09:27.960
This moment.

09:28.760 --> 09:30.920
You can see the.

09:31.160 --> 09:36.200
SYN flood Attack on Port
80 starts happening.

09:37.520 --> 09:40.820
There is a lot of packets.

09:40.850 --> 09:43.720
Targeting Bot 80.

09:52.000 --> 09:54.480
And since we let this attack happen for a

09:54.510 --> 09:59.700
long time, the more you go down
on this capture.

09:59.730 --> 10:03.020
The more you see port 80,

10:03.050 --> 10:09.440
the more you will see our Port 80 on
Windows Machine flooded with SYN packets.

10:17.080 --> 10:20.780
So since we stopped this.

10:20.810 --> 10:30.040
Capturing we can always just go ahead
and save this file and Exploit later.

10:31.800 --> 10:34.020
You can see that the source

10:34.050 --> 10:38.900
are different IPS that
have nothing to do with

10:38.930 --> 10:45.940
the IP of the Linux machine that we sent
this traffic to Windows machine.

10:45.970 --> 10:51.540
That is the power of hping3
randomizing IP address Spoofing

10:51.560 --> 10:56.740
coming from all sorts of different
IP addresses to specific.

10:56.760 --> 11:01.440
one the SYN Flood Attacks.
There is a lot of packets for a long time.

11:02.440 --> 11:05.760
And at some point when we pressed CLT X,

11:06.520 --> 11:14.640
and we stopped the functionality of
this command and the attack stopped.

11:14.880 --> 11:19.040
As you can see,
so in this lesson we explained.

11:19.280 --> 11:24.400
In rather detail, how a TCP
SYN Flood Attack works.

11:24.880 --> 11:31.400
And we also demonstrated how to perform
such an Attack in Kali Linux with hping3.

11:32.320 --> 11:37.340
And we also saw in the targeted machine
how wireshark detected

11:37.370 --> 11:43.740
this TCP SYN Flood Attack
that we send from Kali Linux machine, but

11:43.770 --> 11:48.500
with different IP sources
as we are Spoofing the IPS.

11:48.530 --> 11:51.140
So that was it for this lesson.

11:51.160 --> 11:53.120
And you can just go ahead and click on the

11:53.150 --> 11:57.720
next video where you can learn how
to identify the Bot infected host.

