IPV4 Classful & Classless Networking - Explained
When IP addresses are discussed, the terms Classful and Classless can often be heard. But what is the difference between the two?
Classful IP Addresses
The traditional way of allocating IP addresses, known as Classful addressing, divides the IP address into different classes based on the size of the network. It assigns a range of IP addresses to a host or a network depending on the need. The 4 classes of IP addresses are A, B, C, and D. Each class has a specific range. Class A addresses have a large range of IP addresses, while Class D is used for multicast addresses. It is a very rigid system and is slightly outdated but still very commonly used.
Classful IP addressing is an outdated system for assigning IP addresses that was used until the early 1990s. It defined five classes of IP addresses, each with a different range of possible network IDs and host IDs. Here are the ranges of each class:
Class A addresses:
- Network ID: 1.0.0.0 to 126.0.0.0
- Host ID: 0.0.0.0 to 127.255.255.255
Class B addresses:
- Network ID: 128.0.0.0 to 191.255.0.0
- Host ID: 0.0.0.0 to 255.255.255.255
Class C addresses:
- Network ID: 192.0.0.0 to 223.255.255.0
- Host ID: 0.0.0.0 to 0.0.255.255
Class D addresses (multicast):
- Network ID: 224.0.0.0 to 239.255.255.255
- Host ID: not applicable
Class E addresses (reserved for future use):
- Network ID: 240.0.0.0 to 255.255.255.255
- Host ID: not applicable
Note that classful addressing has been largely replaced by Classless Inter-Domain Routing (CIDR), which allows for more flexible allocation of IP addresses.
Classless IP Addresses
Classless IP addressing, also known as CIDR (Classless Inter-Domain Routing), is a more recent IP addressing scheme which differs from its predecessor in that it allows for flexible subnetting. This means that organizations can choose the amount of IP addresses they need and use only that many. Thus, the user can customize the IP address range according to the number of devices used by any organization. As compared to classful addressing, CIDR is much more efficient when it comes to utilizing IP addresses.
Both classful and classless IP addressing schemes have their own advantages and disadvantages. Classful addresses allow for an easier allocation of IPs, while classless addresses offer greater flexibility. Ultimately, the choice of either one depends upon the individual requirements of organizations and users.
Unlike classful IP addressing, which divides the address space into five classes with fixed boundaries, classless IP addressing allows for more flexible allocation of IP addresses. Instead of pre-defined classes, classless addressing uses a variable-length subnet mask (VLSM) to divide the address space into smaller subnets, allowing for more efficient use of IP addresses.
Here are some examples of classless IP addresses with their corresponding subnet masks:
-
10.0.0.0/8 (10.0.0.0 - 10.255.255.255): This is a private IP address range that can be used within a local network.
-
172.16.0.0/12 (172.16.0.0 - 172.31.255.255): This is another private IP address range that can be used within a local network.
-
192.168.0.0/16 (192.168.0.0 - 192.168.255.255): This is a third private IP address range that can be used within a local network.
-
169.254.0.0/16 (169.254.0.0 - 169.254.255.255): This is an auto-configuration IP address range that is used when a device cannot obtain an IP address through DHCP.
-
198.51.100.0/24 (198.51.100.0 - 198.51.100.255): This is an example of a Classless Inter-Domain Routing (CIDR) address that defines a network with a 24-bit subnet mask.
Note that these are just a few examples of classless IP addresses, and there are many other possible combinations of IP addresses and subnet masks that can be used in classless addressing.