Вы находитесь на странице: 1из 8

Assignment # 6

Assigned Date: - 14-06-2020


Submission Date:-18-06-2020

Summer Semester 2020

Degree:BS(CS)

NAME:

Roll Number:

Course Name:Computer Communication & Networks

Course Code:CS-311

Instructor:Assistant Professor Muhammad NamanChaudhry

NFC-Institute of Engineering and Technology, Multan


Assignment no.6 (Theory)

Note: Attempt all questions. Any type of plagiarism strictly prohibited.


If any found, according to institute policy necessary actions will be
taken. At least punishment is carrying zero marks in Sessional.
1. What is the number of bits in an IPv4 address? What is the number of bits in anIPv6
address?

ANSWER:

The IPv4 addresses we are all used to seeing are made up of four numerical octets that combine to
form a 32-bit address. IPv6 addresses look nothing like IPv4 addresses. IPv6 addresses are 128 bits
in length and are made up of hexadecimal characters.

In IPv4, each octet consists of a decimal number ranging from 0 to 255. These numbers are typically
separated by periods. In IPv6, addresses are expressed as a series of eight 4-character hexadecimal
numbers, which represent 16 bits each (for a total of 128 bits). As we'll see in a minute, IPv6
addresses can sometimes be abbreviated in a way that allows them to be expressed with fewer
characters.

2. What is dotted decimal notation in IPv4 addressing? What is the number of bytesin
an IPv4 address represented in dotted decimal notation? What is
hexadecimalnotation in IPv6 addressing? What is the number of digits in an IPv6
address representedin hexadecimal notation?
ANSWER:

The most obvious and recognizable difference between IPv4 and IPv6 is the IPv6 address. An
IPv4 address is 32 bits and expressed in dotted-decimal notation, whereas an IPv6 address is 128
bits in length and written in hexadecimal. However, there are many other differences between the
two protocol addresses. IPv6 includes new address types as well as changes to familiar address
types.
3. What are the differences between Classful addressing and classless addressing in
IPv4?

 Classless routing and classful routing.  Classless routing causes a router to use its default
routes for any packet that does not match some other route.  Classful routing places one
restriction on when a router can use its default route, resulting in cases in which a router has a
default route but the router chooses to discard a packet rather than forwarding the packet based
on the default route.
The terms classless and classful also characterize both IP addressing and IP routing protocols, so
a fair amount of confusion exists as to the meaning of the terms.
Classless addressing and classful addressing refer to two different ways to think about IP
addresses.  Both terms refer to a perspective on the structure of a subnetted IP address.  Classless
addressing uses a two-part view of IP addresses, and classful addressing has a three-part view. 
With classful addressing, the address always has an 8-, 16-, or 24-bit network field, based on the
Class A, B, and C addressing rules.  The end of the address has a host part that uniquely
identifies each host inside a subnet.  The bits in between the network and host part comprise the
third part, namely the subnet part of the address.  With classless addressing, the network and
subnet parts from the classful view are combined into a single part, often called the subnet or
prefix, with the address ending in the host part.
The terms classless routing protocol and classful routing protocol refer to features of different
IP routing protocols.  These features cannot be enabled or disabled; a routing protocol is, by its
very nature, either classless or classful.  In particular, classless routing protocols advertise mask
information for each subnet, giving classless protocols the ability to support both VLSM and
route summarization.  Classful routing protocols do not advertise mask information, so they do
not support VLSM or route summarization.
As Applied To Classful Classless
Addresses Addresses have three parts: network, subnet, and host. Addresses have two parts: subnet or prefix, and host.
Routing protocol does not advertise masks nor Routing protocol does advertise masks and support
Routing protocols
support VLSM; RIP-1 and IGRP VLSM; RIP-2, EIGRP, OSPF.

Routing IP forwarding process is restricted in how it uses the IP forwarding process has no restrictions on using the
(forwarding) default route default route

4. List the classes in Classful addressing and define the application of each class
(unicast,multicast, broadcast, or reserve).

ANSWER:

"Classes A, B, and C are used for unicast communication. Class D is for multicast
communication and Class E addresses are reserved for special purposes."

5. Explain why most of the addresses in class A are wasted. Explain why a medium-
sizeor large-size corporation does not want a block of class C addresses.
ANSWER:
"A block in class A address is too large for almost any organization. This means most of the
addresses in class A are wasted and not used. A block in class C is probably too small for
many organizations."
A class A subnet has 24 bits worth of addressing, which is enough for almost 17 million
individual devices. Most entities have only a small fraction of this number of devices, so
most of the addresses are not used.

6. What is a mask in IPv4 addressing? What is a default mask in IPv4 addressing?


ANSWER:
In IPv4 there are three default subnet masks corresponding to the three classes of IP addresses
(as illustrated earlier). There are currently three ways of showing the subnet masks for IPv4
addresses; you can show them in dotted decimal, binary, or classless interdomain
routing (CIDR). Dotted decimal is shown in, the binary notation for a Class A default mask
would look like 11111111.00000000.00000000.00000000 and finally the CIDR notation uses a
slash/then the number of bits that need to be turned on in the mask. So for a Class A it would be /
8, for Class B it would be /16, and finally for a Class C it would be /24.
7. What is the network address in a block of addresses? How can we find the
networkaddress if one of the addresses in a block is given?

ANSWER:

The network address is the beginning address of each block. beginning address of each
block. It can be found by applying It can be found by applying the default mask to the
default mask to any of the addresses in the block any of the addresses in the block
(including itself). (including itself). It retains the It retains the netid netid of the block of
the block and sets the and sets the hostid hostid to zero

8. Briefly define subnetting and supemetting. How do the subnet mask and
supemetmask differ from a default mask in Classful addressing?

ANSWER:

"A subnet mask is used to identify which parts of the ip address are the network parts and
which parts are the host parts. "

"In subnetting, a large address block could be divide into several contiguous groups and
each group be assigned to smaller networks called subnets. In supermetting, several small
address blocks can be combined to create a larger range of addresses. The new set of
addresses can be assigned to a large network called a supermet. A subnet mask has more
consecutive 1s than the corresponding default mask. A supermet mask has less
consecutive 1s than the corresponding default mask”.

9. How can we distinguish a multicast address in IPv4 addressing? How can we do


soin IPv6 addressing?
ANSWER:

"Multicast addresses in IPv4 are those that start with the 1110 pattern. Multicast
addresses in IPv6 are those that start with the 11111111 pattern.
Some sort of multicast target is often a logical identifier for the number of hosts within a
computer system network, that you can get to help process datagrams or perhaps frames
can be multicast for a given net service

10. What is NAT? How can NAT help in address depletion?

ANSWER:

"Home users and small businesses may have created small networks with several hosts
and need an IP address for each host. With the shortage of addresses, this is a serious
problem. A quick solution to this problem is called network address translation (NAT).
NAT enables a user to have a large set of addresses internally and one address, or a small
set of addresses, externally. The traffic inside can use the large set; the traffic outside, the
small set."

11. What is the address space in each of the following systems?

ANSWERS:

a. A system with 8-bit addresses


28 ¿256
b. A system with 16-bit addresses9
216¿65,536
c. A system with 64-bit addresses
264¿1.844x1019

12. An address space uses the three symbols 0, 1, and 2 to represent addresses.If each
address is made of 10 symbols, how many addresses are available in thissystem?

ANSWERS:
 
3 possible options for 10 symbols, so 310= 59,049

13. Find the class of the following IP addresses.


a. 11110111 11110011 10000111 11011101
b. 10101111 11000000 11110000 00011101
c. 11011111 10110000 00011111 01011101
d. 11101111 11110111 11000111 00011101
14. In a block of addresses, we know the IP address of one host is 25.34.12.56/16.What
are the first address (network address) and the last address (limited
broadcastaddress) in this block?
ANSWER:
a) We set the 32-n rightmost bits to 0 to get the first address:
25.34.0.0
b).We set the 32-n rightmost bits to 0 to get the first address:a.
25.34.255.255

15. An organization is granted the block 16.0.0.0/8. The administrator wants to


create500 fixed-length subnets.
a. Find the subnet mask.
b. Find the number of addresses in each subnet.
c. Find the first and last addresses in subnet 1.
d. Find the first and last addresses in subnet 500.
ANSWER:

a. Find the subnet mask.

i) 500 subnets means we need log2500 bits reserved in addition to the current
mask, so 8+9 = 17 bits total. The mask is /17
b. Find the number of addresses in each subnet.
i) We can have 232-n addresses per subnet, so 215 i. = 32,768

c. Find the first and last addresses in subnet 1


i. First address is 16.0.0.0
ii. To get last address, set 32-n rightmost bits to 1: 16.0.127.255

d. Find the first and last addresses in subnet 500.

i. First address: 16.249.128.0


ii. Last address: 16.249.255.255
16. An organization is granted the block 211.17.180.0/24. The administrator wants
tocreate 32 subnets.
a. Find the subnet mask.
b. Find the number of addresses in each subnet.
c. Find the first and last addresses in subnet 1.
d. Find the first and last addresses in subnet 32.
ANSWER:

a. Find the subnet mask 2 32-29


Log232 = 5, so 5+24 = /29

b. Find the number of addresses in each subnet


232-29 = 8 addresses per subnet

c. Find the first and last address in subnet


i. First address: 211.17.180.
ii. Last address: 211.17.180.7
c. Find the first and last address in subnet 32
i. First address: 211.17.180.248
ii. Last address: 211.17.180.255
17. An ISP is granted a block of addresses starting with 120.60.4.0/22. The ISPwants to
distribute these blocks to 100 organizations with each organizationreceiving just
eight addresses. Design the subblocks and give the slash notationfor each subblock.
Find out how many addresses are still available after theseallocations.

ANSWER:

The ISP was given 232-n or 210 = 1024 addresses. These can be broken up into 100 8-
address blocks to be distributed to the organizations while the ISP can retain the remaining
addresses for later distribution. Each organization will receive a block with a /29 subnet since
23 = 8 hosts and 32-3 = 29.
• Subnet 1: 120.60.4.0/29 to 120.60.4.7
• Subnet 2: 120.60.4.8/29 to 120.60.4.15
•…
• Subnet 100: 120.60.7.24/29 to 120.60.7.31

ii. We used 800 addresses (8 * 100 organizations) out of a possible 1024. So, 1024-800 =
224 addresses left

18. Show the shortest form of the following addresses.


a. 2340: lABC:119A:AOOO:0000:0000:0000:0000
i) 2340:1ABC:119A:A000::0

b. OOOO:OOAA:OOOO:OOOO:OOOO:OOOO: 119A:A231
i) 0:AA::119A:A231

c. 2340:0000:0000:0000:0000: 119A:AOO1:0000
i) 2340::119A:A001:0

d. 0000:0000:0000:2340:0000:0000:0000:0000
i) 0:0:0:2340::00

19. Show the provider prefix (in hexadecimal colon notation) of an address assignedto a
subscriber if it is registered in the United States with ABC1 as the
provideridentification.

ANSWER:

A:
58ABC1

.Show in hexadecimal colon notation the IPv6 address


a. Compatible to the IPv4 address 129.6.12.34
b. Mapped to the IPv4 address 129.6.12.34
A:
a. 0000:0000:0000:0000:0000:0000:8106:0C22 or 0::8106:C22
b. 0000:0000:0000:0000:0000:FFFF:8106:0C22 or 0::FFFF:8106:C22

. Show in hexadecimal colon notation


a. The link local address in which the node identifier is 0:: 123/48
b. The site local address in which the node identifier is 0:: 123/48
A:
a. FE80:0000:0000:0000:0000:0000:0000:0123 or FE80::123
b. FEC0:0000:0000:0000:0000:0000:0000:0123 or FEC0::123

20. A host has the address 581E: 1456:2314: ABCD:: 1211. If the node identification
is48 bits, find the address of the subnet to which the host is attached.
ANSWER:
The node identifier is 0000:0000:1211. Assuming a 32-bit subnet identifier, the
subnet address is 581E:1456:2314:ABCD:0000 where ABCD:0000 is the subnet
identifier

Вам также может понравиться