Lesson 3 / 8
Module 2Lesson 3⏱ 50 min study

IPv4 Subnetting, RFC 1918 Private Addressing & IPv6 Transition

Deconstruct IPv4 32-bit architecture into network and host portions, compute CIDR subnet boundaries (/24, /28), understand private address pools, and explore IPv6 SLAAC address assignment.

✦ Key Architectural Takeaways
  • •An IPv4 address consists of 32 binary bits divided into four 8-bit octets expressed in dotted-decimal notation
  • •The Subnet Mask defines where the Network ID ends and the Host ID begins; a /24 mask (255.255.255.0) provides 254 usable host addresses
  • •RFC 1918 reserves three private address spaces (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16) that are non-routable on the public internet
  • •IPv6 expands address space to 128 bits (hexadecimal notation), eliminating the need for NAT through globally unique addresses and Stateless Address Autoconfiguration (SLAAC)

## Logical Addressing: The Routing Coordinates of the Internet

Just as physical postal mail requires a street name and house number to reach a recipient, digital networks require structured logical addresses to route data packets between interconnected devices.

In this lesson, you will master the structure of IPv4 (Internet Protocol Version 4), calculate subnet boundaries, navigate private IP reservations, and understand how IPv6 resolves IPv4 address exhaustion.

§

1. The Anatomy of an IPv4 Address

An IPv4 address is a 32-bit binary number represented as four decimal numbers separated by dots (dotted-decimal notation). Each number is known as an octet because it represents 8 binary bits (2^8 = 256 possible values, from 0 to 255):

TEXTSYSTEM SCHEMATIC
  DOTTED-DECIMAL:          192     .     168     .      1      .     150
                            |             |             |             |
  BINARY CONVERSION:    11000000   .   10101000   .  00000001   .  10010110
                        [8 bits]       [8 bits]      [8 bits]       [8 bits]  = 32 BITS

The Role of the Subnet Mask

An IP address alone does not reveal which network a device belongs to. The Subnet Mask is a 32-bit sequence of consecutive binary ones followed by consecutive binary zeros:

  • Binary 1s: Designate the Network ID (must match for all devices on the same local broadcast domain).
  • Binary 0s: Designate the unique Host ID (must be unique for each client host).
TEXTSYSTEM SCHEMATIC
  IP Address:     192.168.1.150      ->  11000000.10101000.00000001 . 10010110
  Subnet Mask:    255.255.255.0      ->  11111111.11111111.11111111 . 00000000
                                         |--------- NETWORK ID -------|--- HOST ID ---|
  
  CIDR Notation:  192.168.1.150/24   (/24 means 24 consecutive binary 1s)
  Network Address: 192.168.1.0        (Identifies the entire subnet)
  Broadcast Address: 192.168.1.255    (Transmits to all hosts on the subnet)
  Usable Host Pool: 192.168.1.1 through 192.168.1.254 (254 Total Assignable Hosts)
§

2. RFC 1918: Private vs Public IP Space

Because 32 bits yield only 2^{32} approx 4.29 billion theoretical IPv4 addresses, the Internet Engineering Task Force (IETF) created RFC 1918, reserving three blocks of addresses strictly for private internal networks:

TEXTSYSTEM SCHEMATIC
  +---------------------------------------------------------------------------------+
  | RFC 1918 PRIVATE IP ADDRESS BLOCKS (NON-ROUTABLE ON PUBLIC INTERNET)            |
  +-------+-----------------------------+-------------------+-----------------------+
  | Class | IP Address Block            | CIDR Prefix       | Available Host IPs    |
  +-------+-----------------------------+-------------------+-----------------------+
  | **A** | 10.0.0.0 - 10.255.255.255   | 10.0.0.0/8        | 16,777,214 hosts      |
  | **B** | 172.16.0.0 - 172.31.255.255 | 172.16.0.0/12     | 1,048,574 hosts       |
  | **C** | 192.168.0.0 - 192.168.255.255| 192.168.0.0/16    | 65,534 hosts (Typical)|
  +-------+-----------------------------+-------------------+-----------------------+

[!IMPORTANT] Internet routers instantly drop any packet with a destination or source address inside an RFC 1918 range. Devices using private addresses can only communicate across the global internet through Network Address Translation (NAT).

§

3. DHCP Automation: The DORA Process

Rather than manually configuring static IP addresses on every smartphone, smart TV, and laptop, your home router runs a DHCP (Dynamic Host Configuration Protocol) server that leases IP configurations dynamically:

TEXTSYSTEM SCHEMATIC
  Client Device                                             Router DHCP Server
        |                                                           |
        |  1. DHCP DISCOVER (Broadcast: 255.255.255.255)            |
        |---------------------------------------------------------->|
        |  "Does anyone have an IP address available for my MAC?"   |
        |                                                           |
        |  2. DHCP OFFER (Unicast or Broadcast)                     |
        |<----------------------------------------------------------|
        |  "I have 192.168.1.105 available with mask 255.255.255.0" |
        |                                                           |
        |  3. DHCP REQUEST (Broadcast)                              |
        |---------------------------------------------------------->|
        |  "I accept your offer for 192.168.1.105. Please lease it."|
        |                                                           |
        |  4. DHCP ACKNOWLEDGE (Unicast)                            |
        |<----------------------------------------------------------|
        |  "Lease confirmed for 24 hours. Gateway: 192.168.1.1,     |
        |   DNS: 1.1.1.1. Welcome to the network!"                  |

Best Practice: Static DHCP Reservations

For devices hosting local network services (such as a NAS, media server, network printer, or smart home hub), assign a DHCP Reservation inside your router's administration console. The router maps the device's physical MAC address to a fixed IP, ensuring it always receives the exact same IP without requiring static configuration on the client host.

§

4. IPv6: The Next-Generation 128-Bit Protocol

To permanently solve IPv4 exhaustion, IPv6 utilizes 128-bit addresses, providing 2^{128} approx 3.4 imes 10^{38} unique addresses—enough to assign trillions of addresses to every atom on Earth.

TEXTSYSTEM SCHEMATIC
  IPv6 Structure: 8 groups of 4 hexadecimal digits separated by colons:
  2a00:23c7:0c87:d101:e8a1:c3d7:ba7b:bd17
  
  Rule 1: Leading zeros inside any group can be omitted:
  2a00:23c7:c87:d101:e8a1:c3d7:ba7b:bd17

  Rule 2: One contiguous block of consecutive zero groups can be replaced with "::":
  fe80:0000:0000:0000:0000:0000:0000:0001  --->  fe80::1 (Loopback / Link-Local)

Key Advantages of IPv6 for Home Users

  • No NAT Required: Every device receives a globally routable public IPv6 address. Direct peer-to-peer gaming and VoIP calls connect without complex port forwarding or STUN servers.
  • SLAAC (Stateless Address Autoconfiguration): Devices generate their own unique IPv6 addresses automatically upon receiving a Router Advertisement (RA) prefix, operating without requiring a centralized DHCP server.