Afrikaans
Akan
Albanian
Amharic
Arabic
Armenian
Azerbaijani
Basque
Belarusian
Bemba
Bengali
Bihari
Bosnian
Breton
Bulgarian
Cambodian
Catalan
Cebuano
Cherokee
Chichewa
Chinese (Simplified)
Chinese (Traditional)
Corsican
Croatian
Czech
Danish
Dutch
English
Esperanto
Estonian
Ewe
Faroese
Filipino
Finnish
French
Frisian
Ga
Galician
Georgian
German
Greek
Guarani
Gujarati
Haitian Creole
Hausa
Hawaiian
Hebrew
Hindi
Hmong
Hungarian
Icelandic
Igbo
Indonesian
Interlingua
Irish
Italian
Japanese
Javanese
Kannada
Kazakh
Kinyarwanda
Kirundi
Kongo
Korean
Krio (Sierra Leone)
Kurdish
Kurdish (Soranî)
Kyrgyz
Laothian
Latin
Latvian
Lingala
Lithuanian
Lozi
Luganda
Luo
Luxembourgish
Macedonian
Malagasy
Malay
Malayalam
Maltese
Maori
Marathi
Mauritian Creole
Moldavian
Mongolian
Myanmar (Burmese)
Montenegrin
Nepali
Nigerian Pidgin
Northern Sotho
Norwegian
Norwegian (Nynorsk)
Occitan
Oriya
Oromo
Pashto
Persian
Polish
Portuguese (Brazil)
Portuguese (Portugal)
Punjabi
Quechua
Romansh
Runyakitara
Russian
Samoan
Scots Gaelic
Serbian
Serbo-Croatian
Sesotho
Setswana
Seychellois Creole
Shona
Sindhi
Sinhalese
Slovak
Slovenian
Somali
Spanish
Spanish (Latin American)
Sundanese
Swahili
Swedish
Tajik
Tamil
Tatar
Telugu
Thai
Tigrinya
Tonga
Tshiluba
Tumbuka
Turkish
Turkmen
Twi
Uighur
Ukrainian
Urdu
Uzbek
Vietnamese
Welsh
Wolof
Xhosa
Yiddish
Yoruba
Zulu
So I kind of want to go through the
basics again for people who just got
started not sure what to do. They've
installed Ki Linux. Now you kind of it
begs the question, okay, what do I do
now? So just to kind of recap, I'm sure
you've seen a lot of YouTube videos. I'm
sure you've seen a lot of YouTube
tutorials on Kali Linux or maybe just
Linux itself.
I want to kind of go through the basics
again to kind of guide people into this
Linux distribution a little bit better.
Kind of what is it all about? Uh this is
just a beginner video. So I mean if you
already know this stuff there's no point
in watching it. Uh but Kali Linux let me
just go through just dive straight into
it. Kali Linux is a operating system
used by ethical hackers. This operating
system is used w it's widely known for
ethical hacking purposes uh related to
security researching discovering
vulnerabilities on web applications
because of the tools that you would use
in this distribution. There's a lot of
tools and suites which are pre-installed
which you can use to practice your
skills and actually to be a hacker. Um
I'm sure you installed K Linux not to
just play around and play video games.
you installed Ki Linux for the intent to
hack uh responsibly. Of course, I do not
condone any illegal activity and I sure
is don't promote any illegal activity or
any illegal endeavor. I am what you call
a ethical hacker, someone who finds a
vulnerability and loves the opportunity
to report it and actually to do good
because it makes the world a better
place. And I would like to kind of go
through the basics to kind of guide
people into the direction of Ki Linux
itself, you know, because it has 600
tools. And if I try to show 600 tools,
we might be here for 2 weeks or even a
month uh to be, you know, honest. It's
just going to take a long time to show
you 600 tools. I don't think that's
really needed. Um 600 tools is not
really necessary for, you know, your
endeavor. You probably thought, "Do I
need to learn 600 tools, Dicklin?" No,
you don't. You don't need to learn 600.
You probably learn need to learn about
the basics probably around about five at
least. So, we're going to just kind of
go through the basics first. So, when
you install Ky Linux, this is the first
thing that you see. You've got this
drop-own menu here. This menu is just
for uh categories associated with the
particular field you're interested in.
Uh and then in this category has the
tools to do that particular thing. So
for example, reconnaissance is all
about, you know, information gathering.
This is what you call recon or like it
says there, reconnaissance, information
gathering. And it just has a lot of
open-source intelligence tools. It
allows you to discover, find, research
information. That's all this is. Um, so
you know, you got the popular one down
here called Nap. And if you actually
click on it, it just opens it in the
terminal. Because most of these tools
are ter terminal tools. If you don't
know what a terminal is, this terminal
window here, this little window, if you
actually click this icon here, this is a
terminal. It's just like a window
emulator. It's just a window which you
can type other commands commands in to
do something specific. So, if I type in
ls, you can see here it's listed my
files on a computer. So, if I change the
directory by typing cd, which stands for
change directory, into the desktop
directory, where do you think that goes?
It goes into the background. So, you see
this is my desktop environment behind
me. And if I create a folder, so let's
say make directory like this. Make
directory make dur. And let's just say
test. We do that. We can see this folder
just popped up on my screen. And I can
drag it around. It's an actual folder.
If I click on it, so you can see how the
ter terminal emulator can be very handy
when you want to navigate through files
and when you want to navigate through
remote connections and servers and stuff
like that.
So you know you would use the terminal
most of the time to configure
pre-install or even update tools or
software that you would use in
penetration testing. The very first
thing that you should do when you
install K Linux is typing pseudoapp
update and then type a and and put and
and so this is what you call the and
operator which basically means okay run
this command first and then run the
second one. So you can go pseudoapp
upgrade as well. Um, so apt, if you
don't know what this is, it's like an
it's like a package manager. So a
package manager is where you can install
packages, software, and even update it
on your current system without needing
to do a lot of stuff. So you just type
in pseudoapp update, which is going to
fetch the latest packages related to
Kali Linux, which can update current
software and tools that you would use
like Burpu or N Map or whatever it is,
right? Or even Python. uh upgrade
however updates and upgrades the entire
operating system itself um updating the
core packages which makes the operating
system work in Kylo Linux. Uh this works
for any other Linux distribution as
well. It actually upgrades the firmware
and it's pretty nice. So you can see
there it just fetched those packages and
it's configured it and it just bundles
it and it's asking me if I want to
continue to install these other kernel
packages. I'm going to go ahead and do
that. might take a little while
depending on your internet connection,
but it's definitely a necessity if you
want a fast working reliable K Linux
environment when you do penetration
testing or even hack the box like I
always talk about in my videos.
So anyways, uh you can see this folder.
I just dragged it in the bin. It's going
to say empty trash. I don't need that
trash because it is literally trash. Uh
I'm going to minimize my terminal. Don't
close it. Just minimize it. So in the
background it's updating. Uh go to the
applications menu again. So let's have a
look here. So we got reconnaissance. We
just took a look at that. We got burp
sweep which is a popular tool for
intercepting website requests and
applications which helps you analyze
certain requests. It's a lot of
information to handle but you'll get
through it very easily. Um so everything
to do with this category is just
researching and finding stuff. Uh
resource development. It's just
everything to do with like searching for
the right exploit. And honestly, I don't
know what this other stuff is. I haven't
messed with it. The only common ones I
know is search where you search for a
particular exploit that you would use or
run against a vulnerability. Uh MSF
Venom to generate a payload or even
encode payloads which is something that
you get access to. So this is a category
relied strictly on you know gaining
access and having that initial access.
Um, so these are like initial access
tools, you know, it's not like you click
it and then you gain access to it or
something. So you can actually run this
tool against something. So for example,
this tool here called comics is used for
testing command injection
vulnerabilities in a website parameter
just like SQL map. SQL map is used for
SQL injections. This one here comics is
used for command injection. Uh, so it's
very nice. Um, so you do have to do a
lot of research in like web application
security and use Ku Linux as well to
learn about it. That's how I did and
I'll definitely make a tutorial series.
Um, execution tab, everything to gain
access. Again, persistence is like
everything to do with being persistent,
having that persistent access. These are
just tools to gain access to a web
server. Not sure what this top one is.
Uh, privilege escalation. Oh, this is
probably the best thing to learn more
about. Um, privilege escalation is
basically where you have access to a
system already, but you don't have like
higher authority on the system. So, for
example, if you if you for educational
purposes, uh, as an example, if you got
into a vulnerable Windows server
operating system, if you basically
hacked into a Windows computer and
you're you are the basic user, you're
not like the admin user, uh, you can
actually run Win. So, you've got linies
and windpiece. Win is for Windows,
Lindpie is for Linux. So, let's say you
hacked into a Windows computer and you
wanted to find loopholes or find
vulnerable versions in the system. Uh,
Windpiece will automate this for you to
find those things. So, you can do your
research and quickly gain access. Uh,
the same as for Linux. If you hacked
into a Linux server or something like
that, it's the same thing. You can run
linies to find those loopholes and get
higher privileges on the system uh like
root, right? Which is pretty cool. um
defensive evasion,
credential access, discovery. These are
these are actually new tabs that have
been opened, but most of it you'll still
see the same tools. It's pretty nice. Uh
so the there's a lot of uh tools to go
through. I did say 600, but the you
could just take a look at these main
ones in the category, but they do have
it listed as well. Um if you installed
it, of course. But this is actually a
pre-made virtual machine, so I don't
actually think it has 600 tools built
into it. I think it has the basic
necessities for you to do penetration
testing. And of course, you can install
any other tool later on down the line.
All right, let's go back to our
terminal. Let's see if it's updating.
Okay, it's at 14%. So, I'm going to go
ahead and skip the video. So, let's
continue where we left off. So, it's
done upgrading. That's brilliant. And if
you have done this already, just skip
that. Let's get into the basics. So,
type in clear. So, you can actually
clear your terminal. Uh the shortest way
and the quickest way to do it without
typing clear is actually by holding if
you're on Windows CRL L. If you hold
Ctrl L that clears the the terminal as
well. Uh on I think if you're doing it
on VMware Fusion. So this is on Mac. I
think it's command L. Uh so you could
try and do that and it um but yeah. So
clear also does the same thing. So if
you have bunch of stuff on the screen,
you can just type in clear and it clears
the screen. So you can just do command
sorry not command control L if you're on
Windows. Anyways let's get straight into
it. So um the first thing that we just
did in the beginning was change
directory onto our desktop make a
folder. I'll show you that again. So if
you type in cd do that goes back a
folder. So it goes back a directory. So
this itself is an environment. Uh you
can also navigate into folders as well.
So if I type in ls it means list the
files. So that's what we are doing here.
We are listing the files on the system
and we can see here we listing files. We
can see desktop downloads, pictures,
etc. If we downloaded something, we can
go into the downloads folder by typing
CD downloads. And if we type in ls,
there's nothing in this file. Uh to
actually see hidden files, if you want
to find hidden files, you can type in ls
dash a. So what this will do is it will
find hidden directories. And if you
don't know what hidden directories are,
so let me go ahead and create hidden
directory. Just a hidden directory
called hidden or I just do test. Okay,
that's a hidden directory with the dot
in the beginning. That's how you create
a folder that isn't supposed to be seen.
If I do ls, you can see it's not showing
up. If I do ls- a, you can see there the
folder showed up and I get into it. So
it's pretty nice. So in order to remove
a directory we're going to type remove
and then the name of the the folder and
by that it's going to say can't remove
as a directory. So we can just say you
know what let's do pseudo remove test.
Okay it's still going to say that. Let's
say remove remove fully. So this dash rf
means remove fully test. And we can see
there it just removed it. And if I find
it it's not there. So you can see how
helpful it is to rely on the terminal
emulator to navigate through the system,
create files, move files, delete files,
even run commands, tools, etc. Um, so
you can actually have more than one
terminal
uh window open doing certain things. So
it's pretty cool. So you can do cd. So
let's go back a directory. You can see
this is the home directory where the
users are. If I go all the way back, you
can see this is where all the system
files are, the bootloadader, the kernel,
all the packages installed, etc. Um, so
it's everything's in here as well. Yeah,
but just type in cd to go back to the
main directory of our at this start. And
uh, so let's just take it slow. So ls
that lists the files. mk dur with a file
name or sorry a folder name stands for
make directory so this is going to make
a directory and you can name it whatever
you want literally uh you can name it
whatever you want it doesn't matter so
it's it's just a folder right you can
create a folder to do certain things so
you can say okay I want to work on my
website let's just create a folder to
put my code in or something like that
you know um so you can make a directory
by using the mk command um you can also
remove a directory by typing remove and
then the file name or the folder name to
remove And if that doesn't work, you can
use uh remove fully completely remove it
and with pseudo it will remove. Um the
next thing is so like I showed you
before to see hidden files is ls- a and
you can actually see right away it did
list other directories but it also lists
the files that are hidden. So if I do ls
this is the same directory. If I type in
ls- a you can see all these other files
and folders that pop up which is very
nice. And these aren't supposed to be
changed. This is by default installed
already. Um, but you can actually tweak
it and interact with it. So when you
install tools, it configures with your
bash environment. Um, which is very
nice. But anyways, that's awesome,
right? So let's get back into it. So if
we go to the menu here, we took we took
a look at some tools, right? But we
didn't actually run any of them. So
let's go ahead just play around. So if
we type in end mapap,
okay, what happened? It didn't do
anything. Um so NMAP is just a tool
which allows you to scan like open
services and ports on a network. Um but
you can see here nothing obviously
happened but it's because we need to
supply a address to scan. So if we type
in MAP and then a IP this can be a local
area network IP. So a IP address which
is a computer address or or phone
address on your network that you can
scan. I'm not sure why you would do that
but you could do it to see if there's
any ports that are open. You can even do
this to your router, your modem or
whatever. For now, I'm just going to do
my modem, my router, which is
192.168.1.1.
Uh I don't I I'm not sure what yours is,
but to figure that out, what you can run
is there's this thing called net
discover, which basically stands for
network discover. And you can see, okay,
I need to be root for this. Just type in
pseudo.
And you can see it's going to find other
network devices. So devices connected to
the same network. And uh yours should be
like it should tell you what that is. Um
so you can see here this is my modem. It
actually says there. And uh if I do end
mapap, okay, you know the popular
command ping. So you you you send a ping
request to see if it's up and running.
End mapap basically does this request
where it sends out a like a a request to
see if that service or if that port is
open then bring back that result. So
this is what MAP is doing. So if I do
MAPAP and then supply the address, it's
going to go out and perform the scan to
see if there's any services or open
ports is what it's called to try and
test or probe it further. Um, so the
reason why would we a hacker would do
this is to understand how a system works
so they can find a loophole and
potentially gain access to a vulnerable
piece of software in that service. So
it's kind of like that and end mapap is
very helpful in finding these um open
ports and services because you can see
here right away it just displayed that
information. So what are we looking at?
So we've got the port, we've got the
state of the port. So if it's opened, if
the port's closed or filtered, you can
see here and also the service like what
that port is. So we got port 22 on my
network is SSH. So we got a SSH machine
or a session open. We've got port 53. So
there's the HTTPS website running.
That's why we've got two uh ports here
which are related with HTTPS which means
there's a website running and it's open
which is the modem website which we you
actually log in to uh see devices on
your network.
And also you've got these other ports
here. I mean we've got this port here
which is unknown which I don't know what
that is. We could take a look at that a
little bit further. But this is not
really necessarily um anything serious,
but it's pretty cool to play around with
a tool like MAP. I know how how basic it
sounds, but it's really cool because you
could do certain things with it. Um
there's certain like commands and
parameters that you can add to the uh
like inmap tool to perform a in-depth
scan. Uh these are just basic defaults.
But if you type in mm map-h what this
will do is you can actually see all
these parameters that you can actually
run with the tool in map that performs a
certain outcome which is also very nice.
But this is something we can take a look
at in another popular tool that I
usually use or ethical hackers would use
strictly like website penetration
testers is a tool called what web. Now
this isn't like a dangerous tool or
anything. All this does, it just visits
a website and then grabs information
about the website in the headers.
Essentially, what what that would
include is is like what the website's
made in. If I do my website, if I do
declan.com, it's going to go ahead and
it's going to banner grab or grab that
information from my website like uh what
is the website running on, what is it
using, where's it being hosted, um you
know, all that information. So, you can
see here this is this is my thing. Uh,
by the way, this is if you see this
here, like this IP, this isn't my IP.
This is actually where my website is
hosted. So, if you if you know someone
does something silly to this IP address,
uh, you will be in trouble. Not by me,
by the company of Versel. It's just to
give you another perspective on what you
can do with what web. Uh, what web isn't
supposed to identify an IP address. It's
just to form that request to see what
the website's using. So, you can see
here I'm using Versel to host my
website. Now you can also if you were
like a malicious actor you could just go
on Google search up a vulnerable piece
of software or something related to
Versel which I doubt anyways that's kind
of what you would do is identify that
information and then go ahead and do
your research to find if there's any
vulnerable pieces of versions of that
software with the information that you
have to then potentially run against the
target or run against something's
vulnerable. It's just something to keep
in mind of what web basically stands for
what web technologies like what website
what is the website running and what are
we taking a look at. So that's why it's
called what web and uh it's very nice.
It's very nice. So another common tool
that hackers would use or ethical
hackers would use is a tool called
metas-loit. This is a framework that has
a lot of like modules and exploitation
scripts just a lot of like code
pre-written code for vulnerable versions
of software programs like I was just
speaking about before. So in order to
run this framework we can type in MSF
console which is actually the
metas-ploit framework console which we
can actually run in our terminal to use
metas-ploit. Um, so Metas-ploit just
basically it's just a tool that has, as
you can see here, 2529
exports. And you're probably thinking,
"Wow, what could you do with that?" Um,
there's a lot of stuff here that you can
take a look at, but it's actually just a
huge library. So, think of like this.
It's like a huge library of like
payloads, exploits, scanners to test
certain versions of systems. That's kind
of what this is. So, let's say I had
like an old version of
uh like SSH or something. You can type
in search SSH like login or whatever.
And you can see right away as I typed in
search, this is built into the
framework. If I type that again, you can
see here I can use different modules,
exploitation modules or even auxiliary
modules, which basically means testing.
It's not actually attacking it any in
any way. So auxiliary modules just tests
it. Uh so I can actually use these
modules which is just pre-written code
to run against the target to perform
something specific like login or testing
the login or maybe like testing
something like this. Look auxiliary
scanner SSH login. So can we try to log
into the version of SSH? Um SSH is just
like another network tool that allows
you to log in and share files and have
remote access to something. Right? Let's
say I had like an old version of Apache
2 or sorry not Apache 2 just Apache.
So Apache Tomcat like that's a good one.
So like if I search Apache
uh Tomcat
we can see here everything to do with
Apache Tomcat. So over the years
Metas-boy is you know always being
developed. I mean look at this one here
2025. This is very recent and it's an
excellent exploitation module against
Tomcat. So, this is actually quite
recent, but it's always being added on.
It's always been updated because it's a
very handy framework to just get that
testing going to just quickly gain
access or to enumerate further as a
penetration tester to see if the system
is you know flawed or flawless and you
know we proceed with something else
right. So, metas-ploit framework is very
handy in that sense. It's really great
to test systems and test even networks
and old versions of software because you
might just gain access or even better
you might have shell access and then you
could do what we spoke about in the
beginning privilege escalation which is
a major vulnerability in system. So
metas-loit is great. I use it all the
time when I do hack the box retired
machines. It's really good to get your
hands uh on this framework and get good
with it. It's amazing. I think the last
the last thing that I want to talk about
is a thing called search exploit. So
metas-ploit framework has this connected
to what's called a search exploit
website. So there's a website that you
can actually go to. So if I open up my
Firefox browser here, there's actually a
website and it should be bookmarked
here. Okay, it's actually not but it's
called search exploit. So or it's also
called exploitd. So if I go to
exploitdb.com,
it's just like a manual. It's just like
a a website where you can see uh the
latest exploits or people who uploaded
exploits um to test a system, right? Or
website or a vulnerability on a service,
right? But you don't have to go to the
website. You can actually just type in
search exploit on your terminal. For
example, let's do what we did with
metas. So if I do search exploit, let's
search for an exploit related to Tomcat.
Right? Right away, it does the same
thing. Right? So if something's not
already in metas-loit, you can just use
search boy to find that version of
software. So let's say it had a
particular version here that you could
you know test or run the exploit would
be in one of these files. Now these are
text files but you would get something
like this. So denial of service
obviously don't suggest that don't want
to do that but there's like Python sorry
yeah Python files Ruby files here. So
you gotpy Ruby you've got Pearl scripts
here as well. Let's try and do something
like PHP
upload vulnerability or something like
that. So we can do arbitrary. So for
this version of software here called ZOM
ZOM plugg 3.8 uh we can do arbitrary
file upload. So this is just a service
that we can perform a like upload our
files to. Uh we've got the exploit here.
So this is just a PHP reverse shell
which means we can gain access to the
server. Um, so you can see here there's
a lot of like exploits that we could use
even with WordPress and all types of
software, right? So I mean you've got
this script here. So this this ID number
here is to do with Python. So we could
run this Python script to perform this
file upload vulnerability, right? So to
actually find or locate or even get this
script like to even use it, you can
actually just copy this location of the
script here. So go ahead and copy that.
So we can just go ahead and copy this
path name, not like the Python file. But
what we can do is let's just do the
exact same thing again and it will still
do that. But you can see here the path
is here. So we can just go ahead and
just type in copy the path name. And
then we could just rename it to
exploit.py at the end of the file name.
We just can call it exploit.py related
to that service. And now if I type in
ls, you can actually see here the
exploits on my desktop. So you can see
there there's the exploit. But we can
actually go ahead and actually read this
exploit by let's just type in nano. So
nano is where you can actually see and
edit files in on your terminal. So type
in exploit.py and we can actually read
everything to do with this exploit and
this vulnerability. So this is all the
code that makes it work so that we could
gain access to the server. So it's just
like a a nice helpful way to navigate
and just quickly get that exploit
running just to test the system so that
we can provide further information. I
forgot to mention one more thing is that
this operating system is running what's
called DBN Linux
which is highly customizable and this
Linux environment is called XFCE which
is a lightweight version for Ki Linux as
a Linux dro. Anyways,
another handy thing that you can do is
when you open up the terminal and let's
say you want to see what your IP address
is on your Linux machine, you can type
in if config and essentially this
command on Linux will give you the
information needed to understand what is
your IP address for your system.
So if I come up here, you can see I have
Ethernet zero and you can see this
address here is my IP address for my
local computer on my network. So this is
just only LAN local area network IP
address. So this is just the network
your computer IP on your main network.
So yours might say WLAN or WLAN0.
Mine says ETH0. And then this would be
your IP address for your machine. So
let's learn a little bit of like system
commands here because you're going to be
doing this when you do hack the box and
all that type of stuff. So I'm just
going to go through some basic commands
that you can take note of. Um we can
type in unname a and essentially this
will just pull information already from
your system from the color Linux machine
uh about what the operating system is
running. Um so if you did this on a
different Linux distribution it will
pull something else. Um, but it's just
good to bring in that information
because let's say I had access to a
machine, a Linux machine specifically,
and I did unname a it would tell me what
that is. So I could just further
identify more system information.
Another good thing is to run a command
called top. This basically just shows
real time system processes. So think
like task manager on Windows. This is
like that but for Linux. And we can see
uh the P ID, the process ID of the
current program that is open. Um so
we've got basically the root user
running uh in the background here. So we
got the user Ki and then we got the user
root on this session. Uh you can also
see like what is this command associated
with. So this is the terminal. Our
default user Ki Linux user is using
that. Um so you can just press Ctrl C to
go out of it. Um let's actually become a
root user. So the way that you do that
is you by typing pseudo sue just like
that. And by the way pseudo stands for
super user do. So that's why you what
why you type in pseudo when you want to
run a command that needs root uh access
because it prevents you from running
root programs that is not installed on
your system or not. So when you run
pseudo it's running it with root
privileges. So super user which is root
and then do. So that's what pseudo
stands for. Super user do and then so
what we're saying here is we're saying
super user do become super user. Sounds
a little bit weird but that's how it is.
We just it's just pseudo sue. You just
become root and then you're good to go.
And uh you can see we are the root user.
So if we actually delete files and
upload files etc. we delete files, move
files, copy files around the system.
Let's actually check another one. So
let's see if this is installed. So this
is not installed. We can actually go
ahead and install it. So if you type
that and just press Y, it's going to go
ahead and install this command. Uh if
it's installed by default, that's great.
You can just run it. But essentially
HTTOP
is basically what we did before with
top. HTOP is a improved process monitor,
right? So it's exactly like top where we
can see real-time processes, but HTOP
gives you like more of a visualized, you
know, just with colors essentially. like
it just makes it more readable instead
of just looking at white text. The
really cool thing about it is that you
can sort through it um and just copy it
and copy note of it which is very nice.
Uh let's type in free-m
is basically memory that's being used
right now. It's just memory usage
really. That's all that is. There's
nothing too much to it. You can type in
uptime. So there's another Linux
command. If you type in uptime, you can
just see which user has been running for
a certain period of time.
Okay, great. So, we learned a little bit
of some system commands on Linux. Let's
take a look at more networking commands.
So, I showed you fconfig.
So, that's fconfig. We can also do IPA,
which is basically what I showed you
before. We we can identify our host
address on a network. So, you can see
that this is our address. And if you
scroll up here, there's more
information. But that is another great
way to kind of type less instead of
doing that. So you just type in IPA
which is great. Um if config same thing
ping. So ping is just a tool a built-in
command line utility tool to test a
address. So if I was to test my router
on my network, the router, the modem
that gives me access to the internet. If
I just ping it, it just sends request to
the router and then it brings back the
request saying it is up and running. So
if let's say that a server was down or a
website IP address was down and you try
to ping it and then it wasn't pinging,
right? It sent requests but it wasn't
receiving anything that's why it says
unreachable then that means it's down.
Ping is a great utility tool to identify
if a network is stable or not.
Another great Linux command is netstat
which basically just shows open
information like open ports on your
system as well. Um but to specifically
filter this out we can type in net stat.
So go ahead and type in netstat and type
in tn
tulin like this. So this can actually
just show you like which ports are
specifically open. So we've got UDP
ports here, but there's not actually
anything running right now as as active
connection. So there's nothing on here.
Another great one is called trace route.
So if you don't know what trace route
is, so trace route just identifies that
specific route to that host. So it just
bounces. It hops to that host until it
gets to the first address. Right? So
let's say we do trace route declan.com.
Right? It goes from our address, but it
actually does a hop to go back to the
original address. It just shows each
hop. So, it like hops. It's like, okay,
checking this route, checking this
route, checking this route till we get
to the main address that may leak info
about it, like ISP, hosting provider,
the location of the data center, um, or
network segmentation or something like
that. It's just finding and discovering
devices, right? called
misisconfigurations. It's it's another
thing that you could use trace route to
show each hop or router or gateway
between the um attacker or the
investigator and the target. So this
will basically reveal how data travels
across the internet or local networks
which helps understand the structure of
the target network and potential access
points. So that's what you would use
trace route for. But this isn't anything
malicious. It's just bunny hopping. It's
just hopping uh on different network
requests. So, it's just to investigate
more information about like where's the
main address located. Um like uncovering
those details. That's all that is. So,
we took a look at networking commands.
Now, let's focus on some process and
service management commands on Linux. So
like I showed you before about showing
you know processes we could do ps uh aux
which will list the current processes
running on the system. So we don't
actually have to look at that
specifically. But if I was to like open
up firefox. So let me just open up
firefox. So Firefox is running. If I go
back and type in ps aux you can actually
come up here and actually see firefox
running. So you can actually see the
specific session of Firefox that's
running on the system. So if I come down
here um there should be so these were
the commands that I was running prior
but there needs to be okay here we go.
So you can you can see there I'm running
Firefox and you can actually see the
associated um browser. So this is the
one here. So this is the P. So the P is
this and we can actually go ahead and
destroy this session by typing in the
Linux command called kill. So this will
just go ahead and just destroy that
session by just closing that P ID. So if
I do if I copy that P ID and I paste it
in, you can see there the browser's
gone. So if I do that again, if I open
up the browser
and then if I find that it would still
be here. So you can see if I come to the
latest, this is the processor that has
opened for that particular browser. And
if I go here, I can actually destroy
that process by typing in kill and then
the process ID that spawned. And there
we go. It forced closed the browser
completely. It destroyed the session so
that the browser just closed. Right? So
it's not actually running in the
background nor is it running at all. It
just destroyed the process, the session
and just closing the browser completely.
So to start services on Linux, this is
another thing I want to talk about is,
you know, let's say you want to run a
web server. Let's say just for
educational reasons, you want to set up
like a a test page, like a fishing page,
right? um or you want to run your own
web server off your Linux machine on
your local area network. Um you've
actually got Apache 2 installed which is
basically what you would host your
servers on, right? Sorry, your your
files on to host your server. So you can
type in um service Apache 2 which is the
service and then you can type in start.
So if you type in service Apache to
start. So the command service allows you
to run certain services on your system.
So you can run other services. It
doesn't just have to be Apache. whatever
is installed that you can run the
command service. You can just type in
start and then it will go ahead and
start that particular service. So now
Apache 2 is running and like I said
before if we do IPA and we actually go
to our network address sorry our IP
address of our machine and go to that
local port number of the web address
that's running. So Apache 2 will spawn a
web server and uh you can see here this
is on our machine. This is a website
running on our machine. Uh this is just
the default page, but if you upload like
your own code like HTML CSS into this
directory. So you can type in cd /bar
www/html.
And if you go into this directory,
you can see here that's actually what's
being hosted in front of us right now.
So if I actually delete this, so let's
use our Linux commands. So let's copy
this. Copy the whole thing including
this file and this file. Now if I type
in remove, we don't have to do pseudo
because we already root. If I do remove
remove fully and just paste in the files
I want to delete. Enter. We can see here
if I refresh this whole page will
disappear. There we go. So the the HTML
files were deleted. Now there's nothing
on the web page. But we can make our own
HTML file. So if we type in touch. So
this is going to go ahead and create a
file. So touch, let's call it
index.html.
And if we press enter, we type in ls,
it's there. But there's nothing on the
web page, of course, because we actually
need to write the code for the the web
page. So, let's use some of our Linux
skills. So, let's type in nano index
html to go into that file and edit it.
Now, we can actually edit the file. You
can edit whatever you want in this file
and it will show up on the website. But
if you don't know HTML, I won't go too
much into it, but let's just type in a
header. So, let's write some code, some
basic HTML code. So, this is what you
call a header tag. So let's just it's
just a header of a website. Uh so if we
type in header test, we could just say
heading one and we close that. Just like
that. That's a heading. You can just
call it heading if you want
or whatever you want. Test or my
website.
My cool website.
And then you press control X on Windows
or command X on um Mac if you're on Mac
or like VMware Fusion. And then you just
press Y to save and then press enter.
There we go. Now it's saved the file.
Now if we go back and refresh, there we
go. It's a title. It's the heading of
the website. So there we go. So our
website's running because we used the
the command service to run the Apache
server. We went into the directory,
added our own file. Um, so you can see
how this can be beneficial, which is
very cool. So let's go cd. Just go back
to the main directory. We're done with
that. And let's just type in service
Apache 2 stop. So if you go back, if you
do that whole thing again and you go
back, copy your IP address, paste it in
the browser on port 80. You go to it, it
the website's not going to be running
because we close the session by running
service Apache 2 stop. So we stop this
service. So that's another great uh
utility tool built into Linux for us to
run specific services. Um if you want to
see like service status, so you can type
in systemctl.
So systemctl will actually you know
analyze or actually list what services
are running. So you can type in like
let's say status for
Apache 2, right? We can see here it's
disabled. So it's not running, right? It
says inactive. So it's not active
currently. Uh but if we type in if we go
back and type in service Apache 2 start
right and then systemctl
status to see the status the current
status of Apache 2. We can see that it's
currently active. So now it's running.
So systemct ctl is a great way to see
what services are running on the system.
So you can type in system status for SSH
if you're running SSH. I'm not running
SSH but you can see there um if it was
running it will say it's running. So you
can actually pick what service so or
Apache or SSH or something else like
Telnet or FTP. Okay, I don't actually
have FTP um but whatever whatever it can
be right and what I like about systemctl
as well what I like about systemctl is
that you can actually enable and disable
these services at boot time. So let's
say you boot up Kylie Linux and it's
just automatically running, right? Um or
you just want to boot up K Linux and you
don't want to have anything running. You
don't want to have this this service
running at all. Um you can actually
enable that. So you can type in
systemcttl enable and then the service
name. So it could be SSH like I said or
even Apache 2. So when you boot up Ky
Linux, Apache 2 is already running. So
if you do that, it will set it to that.
So when I restart Linux and I boot it up
again, Apache 2 will be running. But we
don't want to do that because we don't
want anyone else browsing on our cool
website, right? So let's just disable
that. So we can type in disable and it
will just disable that functionality. So
when we boot up Linux K Linux or you can
even do this on YUbuntu Linux, uh it
will disable that service from running
once you boot it up. Great. So we took a
look at process and service management.
Now let's look at package management. So
what I showed you in the beginning was
we updated our operating system. We use
the AP package manager to upgrade
certain uh kernel files etc. We just
updated the whole operating system for
Ki Linux to make sure all the tools all
the software that we will use as a
penetration tester is up to date and it
is functional. But let's actually take a
look at package management like Linux
commands for package management a little
bit further. So I showed you now we are
in root. We don't actually have to type
root anymore. Um but we can say you know
apt update make sure it's updated.
That's great. We can do that. It's going
to go to the uh Linux mirror repository
and actually download all packages to
make sure and ensure it's updated. The
next one is upgrade. So, we've upgraded
that. We don't we don't need to do that
again. And by the way, I don't think it
will go through that. Yeah, there we go.
You can see that it's already upgraded
the whole thing. So, we automatically
installed and no longer required to
update it. Okay, that's great. If you
want to install a specific package, you
can type in apt install and then like a
package name. Like we saw before, we had
to you can actually install something
specific. So you can type in apt
install. Let's say Python Python 3,
right? It's already installed. But if
you didn't have Python 3, you can
actually select what package you want to
install on this repository, the K Linux
repository, and it will go ahead and
download that package for you. And by
the way, everything's already
preconfigured with Ki Linux. So it's
absolutely brilliant to have this
operating system for you because you can
just get straight into it and learn. If
you want to remove a package, which I
don't suggest unless it's like malicious
or something like that or you just don't
want it, you can just type in apt remove
and then the file name. So obviously not
Python 3. We don't want to remove Python
3. We need that to run certain scripts,
but you can type in apt remove and then
the file name, but we don't need to do
that. In order to see what packages
we've installed, we can actually type in
apt list and then installed like this to
see what packages are installed on our
operating system for Kylie Linux. So
what packages have we installed already
when we upgraded the system like what
are the packages that we have just
installed. So these there's a lot of
lines here to go through but we can see
here these are some of the basic. So we
got Apache 2, we upgraded that. That's
brilliant. Uh we've got the add user
command as well. A crackeng which is a
tool for cracking Wi-Fi wireless
networks. Um sevenzip for zipping files.
So there's a lot of packages here that
have been updated uh or even downloaded
installed already preconfigured on KO
Linux. Let's explore this a little bit
further. Let's say that you want to
review all the commands we've typed out
already.
So you can actually type in history.
This is a command that will allow us to
see what commands we've typed out
previously. And you can see how helpful
this can be to navigate through a
system, to navigate through our own
machine on Ki Linux, or to even just
remember commands now and then. What I
find really interesting about Ki Linux
or just Linux in general is that you can
actually search for a specific file on
Linux, especially if it's like deep in
the system, like in your files, etc.,
and you can't find it. So let's say you
So let me go ahead and actually create a
file. Uh let's let's just create a
random file in a uh folder really
quickly. Let's let's do it in our opt
folder. So this is just an optional
directory folder. So let's say I created
a file called test.ext,
right? And I go out completely. I'm not
even associated with that user and I
just I'm the regular user as well. That
doesn't really matter. But we can
actually type in find slash the name of
that file. So find is a command in Linux
slash is searching through the entire
operating system or just the entire
system for a file name. So we say find
slashname for that file and we can find
test.ext
and just by doing this it's going to say
permission denied. So, we don't actually
have permissions to do that. But we can
go back and type in pseudo find file
text, right? It's also going to say
permission denied. But we can also see
here there's a lot of other files called
test.ext,
which I find really interesting. But you
can actually see down here. So, with it
searching throughout the whole entire
operating system for other files called
test.ext, you can actually see here,
this is actually where we added our own
file in the optional directory. So, we
can see /opt, that's where we were,
slashext.
test.ext. So you can see how the find
slash So you can see how helpful the
find utility command in Linux can be
helpful for searching through the entire
system to find a specific file. It could
be a word list or a directory or
whatever it is. So it's absolutely
brilliant. So like when you do hack the
box and you gain access, you can try and
find the user flag by typing in find if
you have privilege access privilege
access which is great. And that's the
end of the video. So, we covered a lot
of uh Linux commands in this video and I
hope you learn a lot. If you got any
questions, just reach out to me or just
do some research online. Go on Google,
search up a few things. If you don't
understand it, uh you know, search up
Linux commands on Google or on YouTube
and you can also find and watch other
videos related to Linux. Uh Linux is a
really cool operating system. There's a
lot of Linux distributions out there.
It's not just Ki Linux. You've got
Yubuntu, Arch Linux, K Yubuntu, even
lightweight versions of like other Linux
distros, which is really good. Ki Linux
is strictly made for penetration
testing. It's made for penetration
testers to do all their tasks to be a
hacker, an ethical hacker to be a
penetration tester, which I find really
cool, right? And a lot of people use it
um especially me I use it a lot to
perform security uh tests on my website.
Uh I use it because it has all the stuff
and all the tools preconfigured for me
to run and test my software or even do
like cool videos like this. Yeah. So
it's good. I thank you for watching this
video. I've tried to cover a lot of
Linux commands as possible. If you
enjoyed this video, please give it a
like and subscribe.
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.