Addresses and masks

IP Address

The Internet uses 4 byte addresses to identify all the computers and devices connected to it. Each device has a unique address and this address is used in all communications with that machine. That address is called the IP Address (Internet Protocol). An example of that address might be 158.152.1.43. When you enter an address into a web browser, FTP Client or mail client, the software executes what is called a DNS lookup. This converts the URL (Universal Resource Locator) into the 4 byte number, e.g. www.ftgate.com converts to 194.70.211.254.

Subnet Mask

Often an organization will be allocated a range of addresses. For example all the numbers between 158.152.1.128 and 158.152.1.255. This range is described as a subnet. The usual way of describing a subnet is by quoting the first IP number in the range and specifying a subnet mask. The subnet mask is another 4 byte number. This number is used in a binary comparison of the IP number.

 

An IP Number of 158.152.1.128 and a subnet mask of 255.255.255.128 describes a 128 address subnet.

To determine the range take the IP number and subnet mask and convert them to binary.

 

When comparing two IP numbers to see if they are in the same subnet, each number has the subnet mask applied to them. If the resulting numbers are equal then they are in the same subnet.

 

This is the method used by FTGate when comparing addresses with masks.