Mapping by Mask

Masking is a process that extracts the physical network address from an IP address. Masking can be accomplished regardless of whether it has subnetting or not. Consider two cases in which a network is either subnetted or is not.

With no subnetting, masking extracts the network address from an IP address, while with subnetting, masking also extracts the subnetwork address from an IP address. The masking operation can be done by performing a 32-bit IP address on another 32-bit mask.

A masking pattern consists of a contiguous string of 1s and 0s. The contiguous mask means a string of 1s precedes a string of 0s. To get either the network address or the subnet address, the logical AND operation with the bit-by-bit basis must be applied on the IP address and the mask.

Mapping of a logical address to a physical address can be static or dynamic. Static mapping involves a list of logical and physical address correspondences, but maintenance of the list requires high overhead. Address Resolution Protocol (ARP) is a dynamic mapping method that finds a physical address given a logical address.

An ARP request is broadcast to all devices on the network, while an ARP reply is unicast to the host requesting the mapping. Reverse Address Resolution Protocol (RARP) is a form of dynamic mapping in which a given physical address is associated with a logical addresses. ARP and RARP use unicast and broadcast physical addresses.