IPv4 and IPv6 Addressing

Chapter 7 — IPv4 and IPv6 Addressing | Network+ Study Map
CompTIA Network+ · N10-009 · Objectives 1.7, 1.8 & 3.4

Chapter 7 — IPv4 and IPv6 Addressing

IP addressing gives every network interface a logical Layer 3 identity and provides the hierarchy routers use to deliver packets between networks. This chapter develops that foundation through IPv4 structure and subnet boundaries, special-purpose ranges, IPv6 notation and scopes, automatic address assignment, migration technologies, and practical troubleshooting.

15 sectionsIPv4 + IPv6Worked examplesAddress classifierIPv6 compressorSLAAC builder15-question exam check
IPv4 · 32 BITS192.168.10.25IPv6 · 128 BITS2001:db8::25DUAL STACK · NAT64
01

IPv4 Foundations

An IP address is a logical Layer 3 identifier used by routers to deliver packets between networks. IPv4 uses 32 bits written as four decimal octets; a prefix marks the network bits and the remaining bits identify interfaces within that subnet.

How IPv4 provides logical addressing

IPv4 uses a 32-bit address written in dotted-decimal notation as four 8-bit octets, for example 192.168.10.25. Each octet can represent 0 through 255. A subnet mask or CIDR prefix divides the address into:

  • Network portion: identifies the subnet and is shared by interfaces in that subnet.
  • Host portion: identifies an interface within the subnet.
IP address + prefix length → network identity and host identity

An address belongs to an interface, not permanently to an entire device. A multihomed router or server therefore has multiple IP addresses.

One binary digit

Bit

A bit is 0 or 1. Eight bits form one octet with a decimal range of 0 through 255.

All host bits 0

Network address

Identifies the subnet for routing and is not assigned to an ordinary host.

All host bits 1

Broadcast address

Reaches every IPv4 host in the subnet. Assignable host addresses fall between network and broadcast.

Leading network bits

Prefix length

Written /n; defines the boundary between network bits and host bits.

Core structureIPv4 is hierarchical: network bits identify the subnet; host bits identify an interface inside that subnet.
02

Binary Octet Converter

Enter a decimal octet from 0 to 255 to see its eight binary place values.

Example10101100 = 128 + 32 + 8 + 4 = 172.
03

Historical Address Classes

Early IPv4 networks used classful addressing. The first bits—and therefore the first-octet range—implied a fixed network size. This wasted addresses because organizations often received blocks much larger than required.

ClassFirst octetDefault prefixUse
A1–126/8Very large host networks
B128–191/16Medium networks
C192–223/24Smaller networks
D224–239NoneMulticast
E240–255NoneExperimental / reserved
High priorityClassful ranges remain exam knowledge, but modern networks use CIDR prefix length—not the first octet—to determine the real network boundary.
04

Network, Host & Broadcast

The prefix determines which bits describe the network. In a conventional IPv4 subnet, the first address identifies the network, the last is the directed broadcast, and addresses between them are normally assignable.

Worked example: 192.168.10.77/26

A /26 mask is 255.255.255.192. The block size is 256 − 192 = 64, giving ranges 0–63, 64–127, 128–191, and 192–255. Since 77 falls in 64–127:

  • Network: 192.168.10.64
  • Usable hosts: 192.168.10.65–192.168.10.126
  • Broadcast: 192.168.10.127
Usable hosts = 2^(host bits) − 2 → /26 has 6 host bits → 62 usable hosts
Example networkFirst usableLast usableBroadcast
10.0.0.0/810.0.0.110.255.255.25410.255.255.255
172.16.0.0/16172.16.0.1172.16.255.254172.16.255.255
192.168.100.0/24192.168.100.1192.168.100.254192.168.100.255
Host-bit ruleAll host bits 0 = network. All host bits 1 = broadcast. Assignable hosts fall between them.
05

IPv4 Address Classifier

Select an address to reveal its range and practical meaning.

06

Public, Private & APIPA

Public addresses must be globally unique and may be routed across the Internet. RFC 1918 private addresses are reusable inside organizations and are not forwarded across the public Internet.

Private addressing, NAT, and APIPA

NAT translates private addressing for Internet access. PAT lets many hosts share one public address by tracking transport ports. If DHCP fails, a Windows client may self-assign an APIPA address from 169.254.0.0/16. APIPA supports same-link communication but normally provides no default gateway. Check the DHCP server, relay, VLAN, switch port, and physical or wireless link.

RFC 1918

10.0.0.0/8

Private range 10.0.0.0 through 10.255.255.255.

RFC 1918

172.16.0.0/12

Private only from 172.16.0.0 through 172.31.255.255—not every 172 address.

RFC 1918

192.168.0.0/16

Private range 192.168.0.0 through 192.168.255.255.

DHCP failure clue

169.254.0.0/16

APIPA provides local-link communication but no usable default gateway automatically.

Security notePrivate does not automatically mean secure. Filtering, authentication, segmentation, and patching are still required.
07

CIDR, VLSM & Delivery

CIDR expresses the number of leading network bits as /n. A longer prefix creates a smaller subnet; a shorter prefix covers more addresses. VLSM applies different prefix lengths so each subnet matches its host requirement.

Prefix example

/24

255.255.255.0; 256 total and normally 254 usable addresses.

Prefix example

/27

255.255.255.224; 32 total and normally 30 usable addresses.

Point-to-point

/30

255.255.255.252; four total and traditionally two usable addresses.

DeliveryPatternKey behavior
UnicastOne to onePacket targets one interface
BroadcastOne to allAll hosts in the IPv4 broadcast domain
MulticastOne to subscribed groupUses 224.0.0.0/4
IPv6 differenceIPv6 eliminates broadcast and uses multicast and anycast for discovery and service functions.
08

IPv6 Foundations & Notation

IPv6 uses 128 bits written as eight 16-bit hexadecimal hextets. It greatly expands address capacity and makes autoconfiguration, multicast, anycast, and Neighbor Discovery central features.

Reading an IPv6 address

A full address has eight 16-bit hexadecimal groups called hextets, separated by colons. Each hexadecimal digit represents four bits. A typical LAN uses a /64: the leading 64 bits identify the prefix and the remaining 64 bits form the interface ID.

IPv6 does not use ARP. Neighbor Discovery Protocol (NDP), carried by ICMPv6, supports router discovery, neighbor resolution, reachability detection, and Duplicate Address Detection. IPv6 has no broadcast; multicast handles discovery and group delivery.

Public Internet

Global unicast

2000::/3 is globally routable IPv6 space.

Same link only

Link-local

FE80::/10 supports neighbour discovery and is never routed beyond the link.

Internal routing

Unique local

FC00::/7 is routable inside an organization but not on the public Internet.

One to group

Multicast

FF00::/8 replaces many functions that used IPv4 broadcast.

09

IPv6 Compression Explorer

Remove leading zeros in each block, then replace one contiguous run of zero blocks with ::. The double colon may appear only once.

Double-colon rule:: can replace one run of consecutive zero blocks only once per address.
10

IPv6 Address-Type Explorer

No IPv6 broadcastIPv6 supports unicast, multicast, and anycast—but has no broadcast address type.
11

SLAAC Sequence Builder

Stateless Address Autoconfiguration (SLAAC) lets a host construct an IPv6 address from information advertised by a router, without a server assigning and tracking an address lease.

Router discovery and validation

  1. The interface creates a link-local address and checks it using Duplicate Address Detection (DAD).
  2. The host may send an ICMPv6 Router Solicitation (RS).
  3. A router returns a Router Advertisement (RA) containing prefix, default-router, lifetime, and configuration information.
  4. The host combines the prefix with an interface ID and performs DAD again.

The RA M flag points to stateful DHCPv6 address assignment; the O flag points to other DHCPv6 information such as DNS settings.

Host starts IPv6 initialization.
12

Modified EUI-64

Modified EUI-64 is a historical method for deriving a 64-bit IPv6 interface identifier from a 48-bit MAC address. Modern systems commonly prefer privacy or stable-random identifiers, but the calculation remains important exam knowledge.

Worked example: 00:1A:2B:3C:4D:5E

Split the MAC, insert FF:FE, and invert the universal/local bit in the first octet. Here 00 changes to 02.

00:1A:2B:3C:4D:5E → 02:1A:2B:FF:FE:3C:4D:5E → 021a:2bff:fe3c:4d5e
1 · SPLITTwo 24-bit halves
2 · INSERTFF:FE in the middle
3 · FLIPInvert the U/L bit
4 · APPENDAdd to /64 prefix
Privacy noteModern systems often prefer randomized or stable privacy identifiers, but EUI-64 remains important exam knowledge.
13

SLAAC, DHCPv6 & Transition

Address configuration and migration solve different problems. SLAAC and DHCPv6 provide addressing information; dual stack, tunneling, and translation enable coexistence.

ModeAddress sourceOther optionsState
SLAACRA prefix + local interface IDRA/RDNSS where supportedNo lease
Stateless DHCPv6SLAACDHCPv6 options such as DNSNo address lease
Stateful DHCPv6DHCPv6 serverDHCPv6 serverTracked lease
Stateless address

SLAAC

Host builds its address from a router-advertised prefix; no lease database is required.

Extra settings

Stateless DHCPv6

SLAAC builds the address while DHCPv6 supplies options such as DNS.

Tracked lease

Stateful DHCPv6

A server assigns and tracks the IPv6 address and supplies options.

Coexistence

Dual stack

Runs IPv4 and IPv6 simultaneously; flexible but both must be operated and secured.

Carry inside

Tunneling

Encapsulates IPv6 across an IPv4-only section, adding overhead and possible NAT complications.

Translate

NAT64

Translates between IPv6-only clients and IPv4-only services, often with DNS64.

Migration ruleDual stack provides both protocols. Tunneling carries one inside another. NAT64 translates between them.
14

IP Addressing Command-Line Practice

Use command-line evidence to determine whether an interface has a valid address, prefix, default route, neighbor entry, and working name resolution.

Troubleshooting order

  1. Inspect the address, prefix, gateway, and DNS configuration.
  2. Test loopback, the local address, then the default gateway.
  3. Test a remote IP to separate routing from DNS.
  4. Resolve an A or AAAA record and test by name.

APIPA suggests DHCP failure. A valid address without a default route limits communication to directly connected networks. Working IP connectivity with failed hostname connectivity suggests DNS.

Get-NetIPAddressAddresses, prefixes, families, origins
Get-NetIPAddress -AddressFamily IPv4IPv4 only
Get-NetIPAddress -AddressFamily IPv6IPv6 only
Get-NetRoute -AddressFamily IPv4IPv4 routes and default route
Get-NetNeighborARP and IPv6 neighbours
Test-NetConnection 127.0.0.1IPv4 loopback
Test-NetConnection ::1IPv6 loopback
Resolve-DnsName example.com -Type AAAAIPv6 DNS record
15

Exam Check

Fifteen review questions drawn directly from the Chapter 7 manual.

Score: 0 / 0
NETWORK+ STUDY MAP · CHAPTER 7 · IPv4 AND IPv6 ADDRESSING