Day1 : Installing Kali Linux
Day 2: Navigating Linux
Github: 100DaysofHacking
Hello Everyone, This is Ayush if you haven’t read the previous blog then you can read it by clicking on above link in which we have discussed important concepts.
Now today in this blog we’ll learn about Computer Networks, because befor going deep down into penetration testing or cybersecurity, you should have a strong understanding of computer networks, so we’ll start from scratch so let’s learn about it.
The first answer which comes in mind is some kind of connectivity, so networking is nothing but when two device connects with each and do communication between each other or share files then a network is established between those two devices and that process of forming network is called networking.
Network is everywhere from your home to school or office or college, when you connect your phone with your Wi-Fi and other devices then a simple home network is formed i.e called LAN (Local Area Network) , we’ll come on that point later down.
In the above image you can see many devices are connected with Wi-Fi and they are doing communication with each other.
No moving forward let’s talk about internet.
The internet is one giant network that consists of many small networks within itself, where small networks are private networks and network which are connecting small network to internet call public network.
You can read more about internet history n all , here.
Moving forward let’s talk about IP Address and MAC Address
To understand IP and MAC let’s talk an analogy , in every house every person has their own name, their fingerprints, and that person is identified by his name or fingerprint. Suppose in any case one person changes his name but still he can be identified through his fingerprint as he can’t change his fingerprint.
Similarly , In computer networks every device has their own IP address and MAC Address which is used to identify them on network. If IP address changes then also device can be identified through MAC. Now let’s talk about IP.
IP Address stands for Internet Protocol Address, as I said earlier it is used to recognise or identify device on a network, every device has their own IP address.
To know about your device IP address just search whatismyipaddress in google, you’ll get your IP.
IP is a set of 32 bit numbers which is divided into four octets in decimals.
Let’s take an example, suppose an IP 192.168.1.2
Here 192 lies in 1st octet , 168 in 2nd octet , 1 in 3rd octet and 2 in 4th octet.
Each octet range is from 0–255 because when we convert any IP into 8 bit decimal then max value of each octet can be 255 that’s why range lies between 0–255.
Ex. IP — 1.1.1.1
Binary_Form: 00000001 00000001 00000001 00000001
If we do all ones then each octet becomes 255.
To understand more clearly about binary conversion read this blog.
Any octet can not go further than 255 like 192.162.256.1 — It’s an invalid IP.
Now many of you will think IP address is random but it’s not IP address is provided by Internet Assigned Numbers Authority (IANA).
There are two forms of IP address one is IPV4 and other is IPV6, let’s see the difference between both of them.
In above image you can see number of address of IPv4 is 2³² which is less than our total population, so we can’t assign IP to each and everyone, that’s why to overcome the shortage of IPv4 IPv6 came in role with 2¹²⁸ addresses. Now let’s talk about MAC address.
MAC address is a 12 character long hexadecimal number or 48 bit which is also used to identify device on network. It’s also known as physical address. This MAC address is called physical address because it’s printed on the NIC card of your machine. In the MAC , first half represent the company that made network card and second half is unique number.
We can also change our mac address in linux and that process is known as spoofing.
To know about IP and MAC in windows and linux enter following commands:
Windows: ipconfig /all
Linux: ifconifg
To spoof MAC Address: We use a tool called macchanger.
Cmnd: sudo macchanger -m your_MAC_Address_Choice eth0
etho0: It’s just an interface, to know just hit ifconfig.
Ping is a command line utility which we basically use to check whether host is alive or not by sending ICMP (Internet Message Protocol Packets).
Let’s do ping google.com
Thank you for reading till here I hope you liked this blog, if yes then please hit a clap button in case of any queries just ping me on instagram, click_here :).
Now will meet in next writeup on networking concept.
Happy Hacking !