WEBVTT

00:00.000 --> 00:03.730
>> First of all, we know
that it's running telnet.

00:04.010 --> 00:06.510
Since I'm in the script folder,

00:06.510 --> 00:10.230
I'm going to go ahead
and do a dir and all

00:10.230 --> 00:16.980
the telnet related attacks

00:16.980 --> 00:20.415
or exploits that we
can run in and map

00:20.415 --> 00:26.775
against telnet enabled devices.

00:26.775 --> 00:30.990
There's a telnet brute script.

00:30.990 --> 00:34.750
We'll go ahead and run Nmap,

00:37.250 --> 00:45.970
dash a script telnet brute
against that target.

00:59.090 --> 01:02.040
Actually, this isn't

01:02.040 --> 01:05.270
a true brute force
attack that tries

01:05.270 --> 01:06.770
every combination of letters

01:06.770 --> 01:09.380
and numbers and
special characters,

01:09.380 --> 01:11.630
it's really a dictionary attack.

01:11.630 --> 01:17.080
In other words, it uses
a list of credentials.

01:17.780 --> 01:20.630
Because of that, it
actually runs a little bit

01:20.630 --> 01:23.470
faster than a brute
force attack would,

01:23.470 --> 01:26.585
especially given
the fact that we're

01:26.585 --> 01:30.180
having to provide a
username and password.

01:35.500 --> 01:38.960
I didn't adjust the
timing on this attack,

01:38.960 --> 01:43.425
so it'll take a
little bit of time.

01:43.425 --> 01:45.020
In the future, I'll
probably adjust

01:45.020 --> 01:48.870
the timing just to make it
go a little bit faster.

01:53.600 --> 01:57.180
There's the results.
As you all know,

01:57.180 --> 02:00.530
running telnet on any modern
device is a terrible idea.

02:00.530 --> 02:07.070
If any half decent hacker

02:07.070 --> 02:13.025
or network administrator
is listening on traffic,

02:13.025 --> 02:17.060
telnet usernames and
passwords are sent in

02:17.060 --> 02:19.160
plain text and really

02:19.160 --> 02:21.380
without any script
arguments at all,

02:21.380 --> 02:23.870
and not very much time.

02:23.870 --> 02:27.200
This discovered the
username here and

02:27.200 --> 02:31.280
password for that device at 1.2.

02:31.280 --> 02:33.590
Granted, it's not an extremely

02:33.590 --> 02:35.480
complicated username
and password,

02:35.480 --> 02:38.550
but this is it right here.

02:38.750 --> 02:41.715
Just to prove that it works,

02:41.715 --> 02:43.050
I'll clear the screen,

02:43.050 --> 02:45.560
it's the username of
admin and the password of

02:45.560 --> 02:48.775
trustno and then number one.

02:48.775 --> 02:50.370
I'll clear the screen,

02:50.370 --> 02:55.755
we'll do a telnet
of 192.168.1.2,

02:55.755 --> 03:06.880
username, admin, password,
trustno1, and I'm in.

03:07.730 --> 03:10.830
It's a Cisco switch.

03:10.830 --> 03:15.880
I got in with just a
simple NSE script.

03:15.880 --> 03:18.530
Running the vulnerability
scan showed us

03:18.530 --> 03:20.390
what the vulnerability was and I

03:20.390 --> 03:25.700
ran an exploit using the
telnet brute script.

03:25.700 --> 03:31.660
I'll get out of that Cisco
switch, clear the screen.

03:31.660 --> 03:33.875
Another one of the
vulnerabilities had to do with

03:33.875 --> 03:38.070
HTTP since HTTP was open.

03:40.970 --> 03:44.395
I'll do a dir of

03:44.395 --> 03:47.780
all the HTTP attacks that we can

03:47.780 --> 03:50.100
>> run against this device.

03:51.429 --> 03:54.350
>> There's a ton of them.

03:54.350 --> 03:56.750
The one I'm most
interested in is

03:56.750 --> 04:03.415
the default accounts script,

04:03.415 --> 04:08.465
and that is right here.

04:08.465 --> 04:13.470
Go ahead and highlight
it. Copy it.

04:14.230 --> 04:20.370
Clear screen and I'll
do a script help first.

04:28.000 --> 04:31.550
Gives us a ton of detail
about how it works

04:31.550 --> 04:34.790
and what arguments you

04:34.790 --> 04:36.260
can pass to it and where you can

04:36.260 --> 04:38.730
get more information about it.

04:43.160 --> 04:46.900
Really good information.
We'll do an Nmap,

04:46.900 --> 04:54.940
script bot and paste it again
against the same target.

04:58.220 --> 05:01.895
Actually, I'm going to
adjust the timing too,

05:01.895 --> 05:06.230
we'll make it a T5,

05:06.230 --> 05:10.570
which is insane, hit "Enter".

05:10.570 --> 05:13.450
It should go a
little bit faster.

05:19.340 --> 05:25.010
This right here, it shows
me the default accounts.

05:25.010 --> 05:29.130
It's a username and
password of Cisco.

05:29.750 --> 05:32.385
We know it's port 80.

05:32.385 --> 05:36.095
We'll go ahead and open
up our favorite browser,

05:36.095 --> 05:40.000
which is Internet
Explorer. I'm kidding.

05:41.810 --> 05:46.810
We'll navigate to that address.

05:49.280 --> 05:54.120
The username provided in
that NSE script was Cisco

05:54.120 --> 06:00.120
, password was Cisco.

06:08.440 --> 06:10.980
We're in.

06:16.430 --> 06:20.260
Granted. This device

06:20.260 --> 06:21.655
is vulnerable,

06:21.655 --> 06:24.250
I'm not going to
act like it isn't.

06:24.250 --> 06:26.290
It has some obvious flaws,

06:26.290 --> 06:29.920
has a default username
and password enabled,

06:29.920 --> 06:33.975
has a very weak telnet password,

06:33.975 --> 06:38.440
but nevertheless, it was

06:38.440 --> 06:42.820
pretty easy to break in
using standard NSE scripts,

06:42.820 --> 06:44.665
and that's the main point.

06:44.665 --> 06:46.360
We saw the vulnerabilities,

06:46.360 --> 06:48.025
we saw how to attack it,

06:48.025 --> 06:51.200
and usernames and passwords.

06:51.410 --> 06:55.320
Now, I'm going to
minimize this actually.

06:55.320 --> 06:58.630
I want to go over
one more exploit.

06:58.630 --> 07:03.810
That is one that is actually
very common out there.

07:03.950 --> 07:10.910
Don't do this against a
device or a target that

07:10.910 --> 07:15.245
you don't own or

07:15.245 --> 07:18.080
that you don't have a
written contract for.

07:18.080 --> 07:20.735
That is the slowloris attack.

07:20.735 --> 07:24.120
We're going to do a Nmap,

07:33.380 --> 07:37.800
HTTP slowloris, I'll
do the timing of T5.

07:37.800 --> 07:40.010
In this case, it
really matters because

07:40.010 --> 07:42.200
this is a denial
of service attack.

07:42.200 --> 07:45.120
We'll do it against
that same target.

07:48.470 --> 07:51.590
I'm pretty sure that this
one continues to run.

07:51.590 --> 07:53.840
I don't think that
it has a timeout.

07:53.840 --> 07:57.380
While this runs,
it's running against

07:57.380 --> 08:01.915
the same device that
we were just on.

08:01.915 --> 08:03.824
Here's the device.

08:03.824 --> 08:06.405
I'm going to do a
refresh on this device.

08:06.405 --> 08:09.665
You can already see
it's taken it down.

08:09.665 --> 08:14.010
The slowloris attack, the
denial of service attack,

08:14.120 --> 08:17.350
you can look at the details
about how it works,

08:17.350 --> 08:20.185
but it is basically opening up

08:20.185 --> 08:21.610
so many connections against

08:21.610 --> 08:25.250
this web server that
it can't keep up.

08:25.940 --> 08:29.830
I'm not even running it
from multiple hosts.

08:29.830 --> 08:31.810
It's not a
sophisticated denial of

08:31.810 --> 08:33.820
service attack in the sense that

08:33.820 --> 08:37.605
it's not using a botnet or not.

08:37.605 --> 08:38.760
It's not distributed.

08:38.760 --> 08:43.875
It's not a reflective
or amplified attack.

08:43.875 --> 08:50.440
It's a simple attack
against a Cisco switch,

08:50.440 --> 08:53.140
which really could
affect production if

08:53.140 --> 08:57.370
you're in an enterprise network.

08:57.380 --> 09:01.615
Even still, I'm refreshing and,

09:01.615 --> 09:05.690
at least, a web interface is
completely down right now.

09:06.950 --> 09:12.165
I'll go ahead and hit
"Control C" and stop that.

09:12.165 --> 09:14.545
It might take it a second.

09:14.545 --> 09:21.990
I'll minimize the Nmap scan
and I'll do a refresh.

09:21.990 --> 09:24.330
Eventually, the device

09:24.330 --> 09:29.170
should catch up and
be able to respond.

09:30.470 --> 09:34.830
I encourage you to look
into that slowloris attack.

09:34.830 --> 09:40.405
The main point is try it
against your networks,

09:40.405 --> 09:42.850
potentially vulnerable
devices and

09:42.850 --> 09:44.875
see if they can handle it.

09:44.875 --> 09:47.780
Then do a script help

09:47.780 --> 09:51.590
and go to the URL provided
and learn more about it.

09:51.780 --> 09:54.790
Hope this is really
helpful for you and

09:54.790 --> 09:55.450
>> I appreciate you

09:55.450 --> 09:58.990
>> going through this lesson
on Nmap scripting engine.

09:58.990 --> 10:01.670
I'll see you in the next video.

10:01.970 --> 10:04.810
In this lesson, we
answered the questions,

10:04.810 --> 10:07.705
what is Nmap scripting
engine and how does it work?

10:07.705 --> 10:10.480
Next, we examined how the
Nmap scripting engine

10:10.480 --> 10:13.375
gives us the ability to
perform advanced scanning.

10:13.375 --> 10:16.180
Then we went through a lab
that demonstrates its use

10:16.180 --> 10:19.180
as a vulnerability scanner
and exploitation tool.

10:19.180 --> 10:21.255
Thanks so much for going
through this lesson with me,

10:21.255 --> 10:23.830
and I'll see you
in the next one.

