π Day 5 β What is a MAC Address?
π·οΈ Topic: MAC Address
π Key Concept: A unique identifier assigned to every network device at the hardware level.
βΈ»
π§ Introduction
In the world of networking, two crucial addresses help identify devices:
β’ The IP address, which changes based on your location or network.
β’ The MAC address, which never changes β itβs burned into your deviceβs network hardware.
βMAC is like your fingerprint. IP is like your current location.β
This means:
β’ Your IP shows where you are right now.
β’ Your MAC shows who you are, permanently.
βΈ»
π§Ύ What is a MAC Address?
MAC stands for: Media Access Control address.
It is a 12-digit hexadecimal number (usually written in pairs separated by colons or hyphens) assigned to every network interface card (NIC) by the manufacturer.
Example: 00:1A:2B:3C:4D:5E or A8-7B-6C-12-F9-90
This address is unique to each device, making it possible to identify and communicate with that specific piece of hardware on a local network.
βΈ»
π MAC Address vs IP Address
Feature MAC Address IP Address
Stands For Media Access Control Internet Protocol
Assigned By Device Manufacturer Internet Service Provider (ISP) / Router
Scope Local (LAN) Global / Local (Internet or Private LAN)
Format Hexadecimal (e.g., 00:1A:2B:3C:4D:5E) Numeric IPv4 (192.168.1.1) or IPv6
Permanence Fixed (burned into hardware) Dynamic or Static
Visibility Within the local network only Visible to websites and ISPs
βΈ»
π οΈ Where Is MAC Address Used?
β’ Identifying Devices on LAN: Helps switches know where to send data.
β’ Filtering Devices: Used in MAC filtering to allow or block devices on Wi-Fi.
β’ Network Security: Firewalls and routers can use MAC addresses for access control.
β’ Tracking Devices: Some organizations use MAC to monitor who is connecting.
βΈ»
π§ͺ How Does It Work?
Letβs say you have multiple devices connected to your home Wi-Fi:
β’ Your router gives each device an IP address.
β’ But internally, it recognizes each device by its MAC address.
When data is transmitted:
1. The router checks the IP address to decide where the packet goes.
2. Then the switch or access point uses the MAC address to send the packet to the correct hardware.
Itβs like sending a courier to an apartment building (IP address), but delivering it to a specific flat number (MAC address).
βΈ»
π MAC Address Format Breakdown
Example: 00:1A:2B:3C:4D:5E
β’ The first half (00:1A:2B) is the Organizationally Unique Identifier (OUI) β shows who manufactured the NIC (e.g., Intel, Apple, Realtek).
β’ The second half (3C:4D:5E) is device-specific, ensuring uniqueness.
βΈ»
π‘οΈ Can You Change a MAC Address?
β’ Technically yes, itβs called MAC spoofing.
β’ Operating systems allow temporary MAC changes for privacy or testing.
β’ However, the original MAC remains unchanged in the hardware.
βΈ»
π Real-Life Analogy
Letβs compare this to a person:
Element Analogy
MAC Address Your fingerprint (unique ID)
IP Address Your current location
Router Post Office
Device House with fingerprinted owner
A person may move (change IP), but their fingerprint (MAC) stays the same.
βΈ»
π Use Case Examples
Scenario MAC in Action
Parental controls on Wi-Fi Allow/block childβs phone by MAC address
Corporate network security Only allow registered MACs to connect
Network troubleshooting Identify device issues on the network
Wi-Fi authentication MAC-based access filtering
βΈ»
βοΈ Final Thought
βMAC is like your fingerprint, IP is like your current location.β
One stays with you forever (MAC), the other changes as you move or switch networks (IP).
Understanding MAC addresses helps you secure your network, manage devices, and troubleshoot like a pro.