TCP/IP protocol suites 2
- Know the basic concepts of IP addressing including the scheme and classes of IP addresses.
- Compare TCP/IP protocol suites such as Internet Protocol version 4 (IPv4) and Internet Protocol version 6 (IPv6) from an evolutionary perspective.
- Different versions of TCP/IP protocol suites are compared in terms of address size and their support for audio and video.
Internet Protocol (IP):
Features: Similar to UDP, it is unreliable and
connectionless
Functions: IP addressing, encapsulation, routing and
ultimately delivery of the IP packets to correct destination
IPv4 vs IPv6:
IPv4 address is 32-bit long. The number cannot cope with the
huge demand from the expanding network. Thus, IPv6 is developed with its
address which is 128-bit long. Additional features are also available.
Features of IPv6:
128-bit long addresses
Efficient packet handling: e.g. simplified header, traffic
class, flow label
Improved performance: multicast – sending datagrams to
multiple receivers in a single transmission
Improved security: e.g. IPsec fully integrated
Relevant past paper:
DSE ICT Elect B(SP-2017): 2012 2d.
CE CIT(2005-2011): 2009 2c.
IPv4
Address classes:
Binary notation 11000000.10101000.00000000.00000001
Decimal notation 192.168.0.1
The IP address is separated by dots into 4 parts. Each part
is called an octet. The leading bits determine the class.
Network address is for identifying the network while the
host address is for identifying the devices in that network.
Class |
leading bits |
1st octet |
Network address portion |
Host address portion |
A |
0------- |
0-127 |
1st octet |
2nd-4th octet |
B |
10------ |
128-191 |
1st-2nd octet |
3rd-4th octet |
C |
110----- |
192-223 |
1st-3rd octet |
4th octet |
D |
1110---- |
224-239 |
|
|
E |
1111---- |
240-255 |
|
|
Class D and E are not important for the exam purpose.
Relevant past paper:
DSE ICT Elect B(SP-2017):
SP 4e. PP 1di. 2012 4ai.
CE CIT(2005-2011): 2006 4e. 2007 2b. 2008 1f. 2011 3f.
Local(private) vs global(public) IP address:
Some IP addresses
are reserved for private use (use in a LAN). i.e. it cannot be used to identify
a network/host through the internet.
A router is in a
special location where it is between 2 different networks, usually a LAN and
the internet. The ISP assigns a public IP address for the router to use so that
others can identify and reach the router through the internet. The router also
has a private/local IP address so that devices in the LAN can reach the router.
192.168.0.1 is used by many routers as the default (local) IP address.
Relevant past paper:
DSE ICT Elect B(SP-2017):
2017 2ci.
CE CIT(2005-2011): 2009 2f. 2010 4bvii.
AS CA(2000-2013): 2009 9ei.
Network address translation (NAT):
The translation of local IP address into global IP address
and vice versa. This allows the hosts in a LAN to communicate with the outside
world.
A special form of NAT called NAT overload allows multiple
hosts in a LAN to communicate with the outside world using 1 public address
only. This helps to reduce the demand of the limited number of IP addresses.
Port number is used to identify different hosts in the LAN.
NAT table:
Local IP address and source port |
Port number used in NAT |
192.168.0.3:10100 |
20000 |
When data is sent out from an application of a host, the
router received the information 192.168.0.3:10100. This information is saved in
the NAT table in the router and mapped to a new port number. Suppose the public
IP address of the network is 11.100.100.100. The outgoing data will now have a
source IP address and port number as 11.100.100.100:20000.
When returning data targeting 11.100.100.100:20000 reaches
the router, it maps the port number 20000 to the local IP address and port
192.168.0.3:10100. The data will therefore be directed to the relevant host and
application.
Relevant past paper:
DSE ICT Elect B(SP-2017):
PP 1div.
CE CIT(2005-2011): 2009 4c. 2010 4biv.
AS CA(2000-2013): 2007 2c.
Subnetting:
Reason for subnetting:
Usual IP address can be divided into network and host number
based on its class as mentioned before. This represents 1 network with certain
number of hosts. To facilitate network management, for example a large company,
we want to divide the single network into a number of networks.
Use binary notation for understanding
Without subnet:
IP address 192.168.123.132 11000000.10101000.01111011. |
10000100
(Default) subnet mask 255.255.255.0 11111111.11111111.11111111.
| 00000000
Network
address Host address
The subnet mask determines which point to divide the IP
address into network address and host address.
The default subnet masks for class A, B and C addresses are
255.0.0.0, 255.255.0.0 and 255.255.2552.0, respectively.
Subnetting a private network:
To divide a network into 4 networks, we use subnet mask
255.255.255.192 for a class C address.
IP address 192.168.123.0 11000000.10101000.01111011.00
| 000000
Subnet mask 255.255.255.192 11111111.11111111.11111111.11 |
000000
Network
address Host address
So, the four networks are:
11000000.10101000.01111011.00(000000) 192.168.123.0 host addresses: 1-62
11000000.10101000.01111011.01(000000) 192.168.123.64 host addresses: 65-126
11000000.10101000.01111011.10(000000) 192.168.123.128 host addresses: 129-190
11000000.10101000.01111011.11(000000) 192.168.123.192 host
addresses: 193-254
For a class C network:
No of subnets |
Subnet mask 255.255.255.x x = |
In binary notation x = |
Number of subnets |
Number of host addresses in each subnet |
Number of hosts in each subnet * |
2 |
128 |
10000000 |
21 |
27=128 |
128-2 |
4 |
192 |
11000000 |
22 |
26=64 |
64-2 |
8 |
224 |
11100000 |
23 |
25=32 |
32-2 |
16 |
240 |
11110000 |
24 |
24=16 |
16-2 |
32 |
248 |
11111000 |
25 |
23=8 |
8-2 |
64 |
252 |
11111100 |
26 |
22=4 |
4-2 |
* The first and last address of a subnet cannot be assigned
to a host.
Advantages of subnetting:
- Access control
- Data traffic management
Disadvantages of subnetting:
- Increased hardware cost
- Network management work more complicated
Relevant past paper:
DSE ICT Elect B(SP-2017):
PP 1dii. 2012 4aii. 2013 1aii. 2014 1c, 2a. 2015 3di. 2016 4a, bi. 2017
4c.
CE CIT(2005-2011): 2009 4d.
AS CA(2000-2013): 2008 3ab. 2009 9cii, di, ii. 2012 7bc, 10dii. 2013 10 bi.
References:
https://www.plixer.com/blog/network-layers-explained/
https://www.tutorialspoint.com/data_communication_computer_network/transmission_control_protocol.htm
http://www.internet-computer-security.com/Firewall/Protocols/Ports-Protocols-IP-Addresses.html
https://www.tutorialspoint.com/what-is-network-port
https://www.tutorialspoint.com/internet_technologies/internet_protocols.htm
https://www.tutorialspoint.com/ipv6/ipv6_features.htm
https://www.geeksforgeeks.org/network-address-translation-nat/