Networking

Domain Name System (DNS) , IP & MAC Address

Understanding of Domain Name System, IP & MAC Address

I hope you have read my previous article which was about how data is sent from one computer to another.
So every person has an identity by using which other people can identify him.

MAC Address

When a computer is manufactured, they are given a serial number to their Network Adapter or NIC (Network Interface Card) called MAC Address. A MAC Address looks like this 00:A0:C9:24:C3:
It is used to identify devices in a LAN.

IP Address

But when a device (mobile/computer) is connected to internet then MAC Address can’t be used to identify it. It gets a new identity called IP address. Didn’t get it?
When we have to send and receive something from a person who is far away, we need his address right?
Well in case of internet an address is called an IP Address. and here is how an IP Address looks like 193.178.32.64
But it looks too weird for an address right? It looks familiar to a phone number and human brain is bad at memorizing meaningless things for long.

Domain Name System (DNS)

So someone developed a system called Domain Name System. DNS is like a phone book, like a phone book stores numbers with respect to names, so we do not have to memories all those digits. A DNS does exactly the same, it assigns a name called Domain to every IP address. A domain looks like example.com or xyz.in etc.
So whenever we want to go to a website, we enter its domain and then DNS changes it in a computer readable address (IP Address).
Let me explain this process in detail with a graphic
dns domain name system
So I want to visit WebsiteYouWantToVisit.com and I entered its domain in my browser so what happens behind the scenes is:

  1. Your PC then asks your DNS server (Your ISP’s DNS server or some custom server) for the IP address of the server hosting the domain you want to go to.
  2. Your ISP’s DNS server checks the root DNS servers to find out which severs knows about domain you want to visit.
  3. Your ISP’s DNS server then asks that DNS server for the domain you want IP information of.When it receives the information its stores the information for future use (and this process is called caching) and then returns it to your PC.
    Your browser connects to this IP address and asks for a web page.

Your computer then stores the domain name and its respective IP address so it does not have to look it up in DNS Server. The cache of this information is called DNS Cache and hackers can use to perform an attack called DNS Cache Poisoning.
That’s all for now. Thanks for reading.

Also Read: A Beginner’s Guide To Ports


About the author

D3V

I am Somdev Sangwan also known as D3V. I am n00b and I love computers and hacking. I am a python freak and your friendly neighborhood hacker.

6 Comments

Click here to post a comment

Browse Categories:

Subscribe Now

Get the latest post directly into your inbox.

Thank you for subscribing.

Something went wrong.