ITC3303 - Lecture 10 - Introduction To Network Layer
ITC3303 - Lecture 10 - Introduction To Network Layer
• Error Control
• Flow Control
• Congestion Control
• Security
Error Control
• Binary Conversion
• IPv4 Addresses
• Address Space
• Notation
• Subnetting
IP Addressing
• Binary Conversion
128 64 32 16 8 4 2 1
IPv4 Addresses
• The identifier used in the IP layer of the TCP/IP protocol suite to
identify the connection of each device to the Internet is called the
Internet address or IP address.
• An IPv4 address is a 32-bit address that uniquely and universally
defines the connection of a host or a router to the Internet.
• The IP address is the address of the connection, not the host or the
router, because if the device is moved to another network, the IP
address may be changed.
IPv4 Addresses
• IPv4 addresses are unique in the sense that each address defines one,
and only one, connection to the Internet.
• If a device has two connections to the Internet, via two networks, it
has two IPv4 addresses.
• IPv4 addresses are universal in the sense that the addressing system
must be accepted by any host that wants to be connected to the
Internet.
Address Space
• An address space is the total number of addresses used by the
protocol.
• If a protocol uses b bits to define an address, the address space is 2^b
because each bit can have two different values (0 or 1).
• IPv4 uses 32-bit addresses, which means that the address space is
2^32 or 4,294,967,296 (more than four billion).
• If there were no restrictions, more than 4 billion devices could be
connected to the Internet.
Notation
Binary
• In binary notation, an IPv4 address is displayed as 32 bits.
• To make the address more readable, one or more spaces are usually
inserted between each octet (8 bits).
• Each octet is often referred to as a byte.
• For example: 11000001.10100000.00000001.00000000
Notation
Dotted-Decimal:
• To make the IPv4 address more compact and easier to read, it is
usually written in decimal form with a decimal point (dot) separating
the bytes.
• This format is referred to as dotted-decimal notation.
• Note that because each byte (octet) is only 8 bits, each number in the
dotted-decimal notation is between 0 and 255
• For example: 192.168.16.0
Notation
Hexadecimal:
• Sometimes an IPv4 address can be represented in hexadecimal
notation.
• Each hexadecimal digit is equivalent to four bits.
• This means that a 32-bit address has 8 hexadecimal digits.
• For example: 80:0B:03:1F
Hierarchy in Addressing
• In any communication network that involves delivery, such as a
telephone network or a postal network, the addressing system is
hierarchical.
• In a postal network, the postal address (mailing address) includes the
country, state, city, street, house number, and the name of the mail
recipient.
• Similarly, a telephone number is divided into the country code, area
code, local exchange, and the connection.
Hierarchy in Addressing
• A 32-bit IPv4 address is also hierarchical, but divided only into two
parts.
• The first part of the address, called the prefix, defines the network;
• The second part of the address, called the suffix, defines the node
(connection of a device to the Internet).
Hierarchy in Addressing
Classful Addressing
• When the Internet started, an IPv4 address was designed with a fixed-
length prefix, but to accommodate both small and large networks,
three fixed-length prefixes were designed instead of one (n = 8, n =
16, and n = 24).
• The whole address space was divided into five classes (class A, B, C, D,
and E).
• This scheme is referred to as classful addressing.
Classful Addressing
Classful Addressing
Subnet Mask/Default Subnet Mask:
• Subnet mask shows which part is for the network and host portion
• Class A: 255.0.0.0
• Class B: 255.255.0.0
• Class C: 255.255.255.0
Classful Addressing
Slash Notation:
• Class A: /8
• Class B: /16
• Class C: /24
Classful Addressing
• In class A, the network length is 8 bits, but since the first bit, which is
0, defines the class, we can have only seven bits as the network
identifier.
• This means there are only 2^7 = 128 networks in the world that can
have a class A address.
• In class B, the network length is 16 bits, but since the first two bits,
which are (10)2, define the class, we can have only 14 bits as the
network identifier.
• This means there are only 2^14 = 16,384 networks in the world that
can have a class B address.
Classful Addressing