Without DHCP users have to manually enter the IP address, subnet mask and other network parameters in order to join the network. The DHCP server maintains a pool of IP addresses and rents an address to any DHCP-enabled client when the client is enabled. Because IP addresses are dynamic (granted) rather than static (permanently assigned), unused addresses are automatically returned to the pool to be reassigned. As shown in the illustration, when a DHCP-configured device boots or connects to the network, the client transmits a DHCP discovery message (DHCPDISCOVER) to identify any available DHCP servers on the network. A DHCP server responds with a DHCP offer message (DHCPOFFER), which offers a grant to the client. The offer message contains the IP address and subnet mask to be assigned, the IP address of the DNS server and the IP address of the default gateway. The grant offer also includes the duration of the grant.
Now that China is engaged in a joint project between its administration and companies such as Huawei, trying to change the way IP addresses are constructed and how they are operated, it seems a good time to explain how the current ones, which have been in place since the beginning of the Internet as we know it today, work.
As mentioned in the introduction, an IP address is an identifier assigned to each device that connects to the Internet at the time of connection. An identifier that can vary in the case of variable IPs or be permanent in the case of fixed IP addresses. With this IP, our device, whatever it is, will be permanently identified during navigation.
Moreover, it is a mandatory identifier since it is not possible to navigate without this address. The reason is that all websites and programs operating on the Internet send data from one IP, theirs, to another IP, ours. A web page server, for example, has to know to which device to send the page you want to visit. That is the reason why IP addresses cannot be repeated, and why they are constructed in such a way that they make up a path through which a piece of data manages to locate our equipment (a cell phone, a tablet, a computer, a TV, a connected light bulb) in the immensity of devices that exist all over the planet.
Types of ip addresses
If the destination host is not on the same subnet, the sender is directed to the standard gateway (in most cases a router). It can access it via the combination of MAC and IP address, so the Address Resolution Protocol is also needed here. Once the addresses have been resolved, the gateway receives the data packet and then forwards it to the destination host. This gateway analyzes the IP header to obtain the necessary data. Then, using the possibilities of the ARP protocol, it resolves the physical address directly when it is on an adjacent subnet, or resolves the hardware address of another gateway when the destination computer is on a remote subnet and the path of the packet cannot be determined with the help of the routing table.
This type of physical address communication can occur, for example, for the following reasons:The Reverse Address Resolution Protocol (RARP) represents another type of variation that reverses the function of ARP. With this, it is not IP addresses that are resolved to MAC addresses, but rather MAC addresses that are resolved to IP addresses. Devices that are not programmed for allocation or permanent storage, such as workstations without a hard disk, make use of this possibility of finding out one’s own Internet address.
IP address classes and ranges
IP addressing provides a mechanism for assigning identifiers to each device connected to a network. Before giving more technical information, here are the main concepts:
The second important aspect of IP addresses is that they have a hierarchical component. One part of the IP address identifies the network (network prefix) and another part identifies the device (host) within that network.
For this purpose, all bits used to define the network prefix are set to 1 in the mask, and all bits used to define the devices within the network are set to 0.
The criteria for assigning private IP addresses is free, i.e. any of the reserved private IP address ranges can be used. At the end of the article there is a global address table where the private address ranges can be seen.
Typically, operators providing residential Internet access use routers configured with class C private addresses, e.g. 192.168.0.1, 192.168.1.1… but any other private address range could be used.