Skip to main content

IP in Practice: IP Addressing Basics

Whenever you order at a fast-food restaurant, the cashier may give you a number or ask for the name on your order. When your order is ready, they will call your number or name so the correct person receives it. Similarly, devices on a network are assigned a unique number so information reaches its intended destination. This number is called an IP address.

. . .

IP Addresses are Unique Identifiers

Every device on a network has an IP address that allows it to communicate with other devices. These addresses are unique within a network to ensure data reaches its intended destination. Imagine if two people had the same order number—there would be confusion about who ordered what. Similarly, without these identifiers, devices would not know where to send or receive data.

Purposes of IP Addresses

IP addresses serve several purposes, including:

Routing: IP addresses operate at layer 3 of the TCP/IP or OSI model, also known as the Network Layer or Internet Layer. At this layer, devices can send data within LANs and across the internet. Unlike fixed MAC addresses, IP addresses are considered logical addresses because they can change depending on which network a device joins. For example, your MAC may remain the same, but your IP will likely change when you connect to a different network.

Identifying Source and Destination: When two devices communicate, the roles of sender and receiver alternate. An IP packet contains both the source and destination IP addresses so data is correctly routed between devices.

Location: An IP address can indicate the type of network a device is on or its general location. IP address ranges determine whether a network is private or public. Regional Internet registries allocate IP address space for specific regions, while IANA registers these large address blocks globally.

Types of IP Addresses

IP addresses can be grouped by:

Assignment

  • Dynamic IP addresses: Assigned by a DHCP server, which provides network details allowing devices to communicate with others. These addresses may change when joining different networks. Read more on DHCP.
  • Static IP addresses: Manually assigned. These can be reserved so certain devices maintain a consistent IP address for simplicity, convenience, and stability, such as servers, printers, and smart devices.

Communication Method

  • Unicast address: One-to-one communication between two devices. This is the most common type of network communication.
  • Broadcast address: One-to-all communication, sending data to every device on the network. These are often used in ARP requests to find a device's MAC address for a given IP.
  • Multicast address: One-to-many communication, sending data to multiple devices but not necessarily all devices on a network. This is common when casting a screen to several devices.

Scope

  • Private addresses: Defined in RFC1918. These addresses are used within LANs, such as at home or in organizations.
    • There are three ranges of private addresses:
      • Class A: 10.0.0.0 – 10.255.255.255
      • Class B: 172.16.0.0 – 172.31.255.255
      • Class C: 192.168.0.0 – 192.168.255.255
    • Private addresses are not globally routable and must be translated to access the internet.
  • Public addresses: Routable across the internet. Many websites and organizations use these addresses to allow users to access their services.

5 Myths

  • Myth: I should hide my IP address to stay safe online.

    Clarification: Public IP addresses are designed to be globally routable. Home networks use private IP addresses with a router using NAT (Network Address Translation). Each device accesses the internet through the router, which replaces private IP addresses with a public NAT address.
  • Myth: You must cover your IP address on screens.

    Clarification: In typical scenarios, only public IP addresses are exposed beyond a local network. Private addresses are not publicly routable, meaning they cannot be directly accessed from the internet without NAT traversal or physical network access.
  • Myth: Using a VPN hides my IP.

    Clarification: A VPN creates a private, encrypted connection over a public network. Your IP address does not disappear; it is masked by the VPN server’s IP address. Websites see the VPN’s IP address, while your original IP is hidden from them, though it may still be visible to your ISP or the VPN provider.
  • Myth: Never use public Wi-Fi.

    Clarification: Public Wi-Fi can pose risks due to weak or absent encryption. Older standards like WEP, WPA, and WPA2 had weaker protections. WPA2-Personal uses a shared key, which could allow traffic to be intercepted. WPA3 and Enhanced Open create unique keys per device, improving security. It’s generally a good practice to use a VPN, secure websites (HTTPS), and avoid transmitting sensitive information.
  • Myth: I am directly connected to the Internet.

    Clarification: In most home or business networks, devices are not directly public-facing. Routers often use NAT to allow multiple devices to share a single public IP address. NAT converts private IP addresses to a public address for internet access while keeping your network safer.

Next Part

IP addresses have two formats: IPv4 and IPv6. Now that we have covered the basics, let's take a deep dive into IPv4, understanding how it is structured and its types.

Comments

Popular posts from this blog

A Nesting Doll of Networks: Types of Networks

  PAN, WAN, MAN, LAN, CAN - what is up with all these rhyming words? As fun it us to relive kindergarten, these are acronyms for the types of networks that exist today. Think of them as digital nesting dolls: PANs can be found in LANs, LANs make up our WANs, and there is more in between. Let's take a closer look at these networking nesting dolls. Personal Area Networks (PANs) Have you ever grown frustrated at how your Bluetooth headphones seem to take forever to pair to your phone? Do you use a wired mouse or a wireless mouse with your desktop? Do you "tap to pay"? These are examples of personal area networks.  A personal area network connects devices close in range, from a few centimeters to a few meters. These types of networks can be wired or wireless.  A wired PAN may be a computer connected to a printer by a USB cable or Ethernet cable.  A wireless PAN may use communication methods, such as Bluetooth, infrared, or radio waves. Think of your wireless Bluetooth ea...

How to Set Up a Cisco Router as a DHCP Server (Step-by-Step Guide)

Lab time! Want to build a DHCP server?  In this lab, I will show you how to build your own DHCP server on a router using Cisco Packet Tracer, as shown above. By the end of this post, you will be able to create your own DHCP server with a Cisco 2911 router, perhaps in a home lab setting, and prepare you to build your own on other hardware.  Why a Router?  A DHCP server is a centralized, automated service that assigns important network configuration details to devices on a network, such as IP addresses. Without it, we would have to create manual entries for our entire network, which can be time-consuming and lead to errors. Traditionally, there are dedicated servers to handle these functions. There are many ways to implement a DHCP server in your topology, including a dedicated physical server, a virtual machine, cloud-based gateways, and firewalls. However, there are specific benefits to using a router as your DHCP server: Reduced infrastructure: While havi...

Subnetting Tips

When I was first introduced to subnetting, it was difficult to understand the math and the process behind it. I watched videos but it did not click. I focused more on how to calculate it than on the reasoning behind it. Why do we subnet? I remember seeing forward slashes followed by numbers, classes, letters, network and broadcast addresses - important terms that was overshadowed by just trying to grasp why certain numbers were used.  Years later, I hear the word "subnetting" in one of my courses, and it reminded me of my struggles. Yet, I was excited. It was a time for redemption. Example after example, I started to get them right but also got to understand how to create a subnet with sufficient space for devices. Because of this, I have grown to love subnetting.  For me, it took time - a break that lasted about two years followed by a curriculum that focused on the topic for a few weeks. If you find yourself struggling with subnetting, do not worry. It takes time. If someth...