Download as pdf or txt
Download as pdf or txt
You are on page 1of 29

IT1401 Computer Communication Dept.

of IT 2022-2023

UNIT V
TRANSPORT, SESSION AMD APPLICATION LAYER
Transport Layer –UDP, TCP, Congestion Control & Quality of Service – Data traffic,
Congestion, Congestion Control, QoS and Flow Characteristics, Application Layer – DNS,
Remote Logging (Telnet), SMTP, FTP, WWW, HTTP, POP3, MIME, SNMP.

User Datagram Protocol


The User Datagram Protocol (UDP) is simplest Transport Layer communication
protocol available of the TCP/IP protocol suite. It involves minimum amount of
communication mechanism. UDP is said to be an unreliable transport protocol but it
uses IP services which provides best effort delivery mechanism.
In UDP, the receiver does not generate an acknowledgement of packet received and in
turn, the sender does not wait for any acknowledgement of packet sent. This
shortcoming makes this protocol unreliable as well as easier on processing.
User Datagram Protocol (UDP) is a communications protocol that is primarily used to
establish low-latency and loss-tolerating connections between applications on the
internet.
UDP speeds up transmissions by enabling the transfer of data before an agreement is
provided by the receiving party. As a result, UDP is beneficial in time-sensitive
communications, including voice over IP (VoIP), domain name system (DNS) lookup,
and video or audio playback.
UDP is an alternative to Transmission Control Protocol (TCP). Both UDP and TCP run
on top of IP and are sometimes referred to as UDP/IP or TCP/IP. However, there are
important differences between the two. For example, UDP enables process-to-process
communication, while TCP supports host-to-host communication.
TCP sends individual packets and is considered a reliable transport medium. On the
other hand, UDP sends messages, called datagrams, and is considered a best-effort
mode of communications. This means UDP doesn't provide any guarantees that the data
will be delivered or offer special features to retransmit lost or corrupted messages.
UDP provides two services not provided by the IP layer. It provides port numbers to
help distinguish different user requests. It also provides an optional checksum capability
to verify that the data arrived intact.

1
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

User Datagram Protocol features


User Datagram Protocol has attributes that make it beneficial for use with applications
that can tolerate lost data. Below are some examples:
 It allows packets to be dropped and received in a different order than they were
transmitted, making it suitable for real-time applications where latency might be a
concern.
 It can be used for transaction-based protocols, such as DNS or Network Time
Protocol (NTP).
 It can be used where a large number of clients are connected and where real-time
error correction isn't necessary, such as gaming, voice or video conferencing, and
streaming media.
UDP header composition
UDP uses headers when packaging message data to transfer over network connections.
UDP headers contain a set of parameters -- called fields -- defined by the technical
specifications of the protocol.
The User Datagram Protocol header has four fields, each of which is 2 bytes. They are
the following:
 source port number, which is the number of the sender;
 destination port number, the port to which the datagram is addressed;
 length, the length in bytes of the UDP header and any encapsulated data; and
 checksum, which is used in error checking -- its use is required in IPv6 and optional
in IPv4.
UDP Header
UDP header is as simple as its function.

UDP header contains four main parameters:


 Source Port - This 16 bits information is used to identify the source port of the packet.
 Destination Port - This 16 bits information, is used identify application level service
on destination machine.

2
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

 Length - Length field specifies the entire length of UDP packet (including header). It
is 16-bits field and minimum value is 8-byte, i.e. the size of UDP header itself.
 Checksum - This field stores the checksum value generated by the sender before
sending. IPv4 has this field as optional so when checksum field does not contain any
value it is made 0 and all its bits are set to zero.

Transmission Control Protocol


The transmission Control Protocol (TCP) is one of the most important protocols of Internet
Protocols suite. It is most widely used protocol for data transmission in communication
network such as internet.
Features
 TCP is reliable protocol. That is, the receiver always sends either positive or negative
acknowledgement about the data packet to the sender, so that the sender always has
bright clue about whether the data packet is reached the destination or it needs to resend
it.
 TCP ensures that the data reaches intended destination in the same order it was sent.
 TCP is connection oriented. TCP requires that connection between two remote points
be established before sending actual data.
 TCP provides error-checking and recovery mechanism.
 TCP provides end-to-end communication.
 TCP provides flow control and quality of service.
 TCP operates in Client/Server point-to-point mode.
 TCP provides full duplex server, i.e. it can perform roles of both receiver and sender.
Header
The length of TCP header is minimum 20 bytes long and maximum 60 bytes.

 Source Port (16-bits) - It identifies source port of the application process on the
sending device.

3
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

 Destination Port (16-bits) - It identifies destination port of the application process on


the receiving device.
 Sequence Number (32-bits) - Sequence number of data bytes of a segment in a session.
 Acknowledgement Number (32-bits) - When ACK flag is set, this number contains
the next sequence number of the data byte expected and works as acknowledgement of
the previous data received.
 Data Offset (4-bits) - This field implies both, the size of TCP header (32-bit words)
and the offset of data in current packet in the whole TCP segment.
 Reserved (3-bits) - Reserved for future use and all are set zero by default.
 Flags (1-bit each)
o NS - Nonce Sum bit is used by Explicit Congestion Notification signaling
process.
o CWR - When a host receives packet with ECE bit set, it sets Congestion
Windows Reduced to acknowledge that ECE received.
o ECE -It has two meanings:
 If SYN bit is clear to 0, then ECE means that the IP packet has its CE
(congestion experience) bit set.
 If SYN bit is set to 1, ECE means that the device is ECT capable.
o URG - It indicates that Urgent Pointer field has significant data and should be
processed.
o ACK - It indicates that Acknowledgement field has significance. If ACK is
cleared to 0, it indicates that packet does not contain any acknowledgement.
o PSH - When set, it is a request to the receiving station to PUSH data (as soon as
it comes) to the receiving application without buffering it.
o RST - Reset flag has the following features:
 It is used to refuse an incoming connection.
 It is used to reject a segment.
 It is used to restart a connection.
o SYN - This flag is used to set up a connection between hosts.
o FIN - This flag is used to release a connection and no more data is exchanged
thereafter. Because packets with SYN and FIN flags have sequence numbers,
they are processed in correct order.

4
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

 Windows Size - This field is used for flow control between two stations and indicates
the amount of buffer (in bytes) the receiver has allocated for a segment, i.e. how much
data is the receiver expecting.
 Checksum - This field contains the checksum of Header, Data and Pseudo Headers.
 Urgent Pointer - It points to the urgent data byte if URG flag is set to 1.
 Options - It facilitates additional options which are not covered by the regular header.
Option field is always described in 32-bit words. If this field contains data less than 32-
bit, padding is used to cover the remaining bits to reach 32-bit boundary.
Addressing
TCP communication between two remote hosts is done by means of port numbers (TSAPs).
Ports numbers can range from 0 – 65535 which are divided as:
 System Ports (0 – 1023)
 User Ports ( 1024 – 49151)
 Private/Dynamic Ports (49152 – 65535)
Connection Management
TCP communication works in Server/Client model. The client initiates the connection and the
server either accepts or rejects it. Three-way handshaking is used for connection management.

5
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Establishment
Client initiates the connection and sends the segment with a Sequence number. Server
acknowledges it back with its own Sequence number and ACK of client’s segment which is
one more than client’s Sequence number. Client after receiving ACK of its segment sends an
acknowledgement of Server’s response.
Release
Either of server and client can send TCP segment with FIN flag set to 1. When the receiving
end responds it back by ACKnowledging FIN, that direction of TCP communication is closed
and connection is released.
Bandwidth Management
TCP uses the concept of window size to accommodate the need of Bandwidth management.
Window size tells the sender at the remote end, the number of data byte segments the receiver
at this end can receive. TCP uses slow start phase by using window size 1 and increases the
window size exponentially after each successful communication.

6
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

For example, the client uses windows size 2 and sends 2 bytes of data. When the
acknowledgement of this segment received the windows size is doubled to 4 and next sent the
segment sent will be 4 data bytes long. When the acknowledgement of 4-byte data segment is
received, the client sets windows size to 8 and so on.
If an acknowledgement is missed, i.e. data lost in transit network or it received NACK, then
the window size is reduced to half and slow start phase starts again.
Error Control &and Flow Control
TCP uses port numbers to know what application process it needs to handover the data
segment. Along with that, it uses sequence numbers to synchronize itself with the remote host.
All data segments are sent and received with sequence numbers. The Sender knows which last
data segment was received by the Receiver when it gets ACK. The Receiver knows about the
last segment sent by the Sender by referring to the sequence number of recently received
packet.
If the sequence number of a segment recently received does not match with the sequence
number the receiver was expecting, then it is discarded and NACK is sent back. If two segments
arrive with the same sequence number, the TCP timestamp value is compared to make a
decision.
Multiplexing
The technique to combine two or more data streams in one session is called Multiplexing.
When a TCP client initializes a connection with Server, it always refers to a well-defined port
number which indicates the application process. The client itself uses a randomly generated
port number from private port number pools.
Using TCP Multiplexing, a client can communicate with a number of different application
process in a single session. For example, a client requests a web page which in turn contains
different types of data (HTTP, SMTP, FTP etc.) the TCP session timeout is increased and the
session is kept open for longer time so that the three-way handshake overhead can be avoided.
This enables the client system to receive multiple connection over single virtual connection.
These virtual connections are not good for Servers if the timeout is too long.
Congestion Control
When large amount of data is fed to system which is not capable of handling it, congestion
occurs. TCP controls congestion by means of Window mechanism. TCP sets a window size
telling the other end how much data segment to send. TCP may use three algorithms for
congestion control:
 Additive increase, Multiplicative Decrease
7
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

 Slow Start
 Timeout React
Timer Management
TCP uses different types of timer to control and management various tasks:
Keep-alive timer:
 This timer is used to check the integrity and validity of a connection.
 When keep-alive time expires, the host sends a probe to check if the connection still
exists.
Retransmission timer:
 This timer maintains stateful session of data sent.
 If the acknowledgement of sent data does not receive within the Retransmission time,
the data segment is sent again.
Persist timer:
 TCP session can be paused by either host by sending Window Size 0.
 To resume the session a host needs to send Window Size with some larger value.
 If this segment never reaches the other end, both ends may wait for each other for infinite
time.
 When the Persist timer expires, the host re-sends its window size to let the other end
know.
 Persist Timer helps avoid deadlocks in communication.
Timed-Wait:
 After releasing a connection, either of the hosts waits for a Timed-Wait time to terminate
the connection completely.
 This is in order to make sure that the other end has received the acknowledgement of its
connection termination request.
 Timed-out can be a maximum of 240 seconds (4 minutes).
Crash Recovery
TCP is very reliable protocol. It provides sequence number to each of byte sent in segment. It
provides the feedback mechanism i.e. when a host receives a packet, it is bound to ACK that
packet having the next sequence number expected (if it is not the last segment).
When a TCP Server crashes mid-way communication and re-starts its process it sends TPDU
broadcast to all its hosts. The hosts can then send the last data segment which was never
unacknowledged and carry onwards.
Quality of Service(QoS)
8
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Quality of Service(QoS) is basically the ability to provide different priority to different


applications, users, or data flows, or in order to guarantee a certain level of performance to the
flow of data.
QoS is basically the overall performance of the computer network. Mainly the performance of
the network is seen by the user of the Network.
Flow Characteristics
Given below are four types of characteristics that are mainly attributed to the flow and these
are as follows:
 Reliability
 Delay
 Jitter
 Bandwidth

Reliability
It is one of the main characteristics that the flow needs. If there is a lack of reliability then it
simply means losing any packet or losing an acknowledgement due to which retransmission
is needed.
Reliability becomes more important for electronic mail, file transfer, and for internet access.
Delay
Another characteristic of the flow is the delay in transmission between the source and
destination. During audio conferencing, telephony, video conferencing, and remote
conferencing there should be a minimum delay.

9
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Jitter
It is basically the variation in the delay for packets that belongs to the same flow. Thus Jitter
is basically the variation in the packet delay. Higher the value of jitter means there is a large
delay and the low jitter means the variation is small.
Bandwidth
The different applications need different bandwidth.
Steps to achieve Quality of Service:
Quality of Service, can be done by techniques, like jitter buffer and traffic shaping.
Jitter buffer
This is a temporary storage buffer which is used to store the incoming data packets, it is
used in packet-based networks to ensure that the continuity of the data streams doesn't get
disturbed, it does that by smoothing out the packet arrival times during periods of network
congestion.
Traffic shaping
This technique which is also known as packet shaping is a congestion control or
management technique that helps to regulate network data transfer by delaying the flow of
least important or least necessary data packets.
QoS is included in the service-level agreement when an organization signs it with its network
service provider which guarantees the selected performance level.
There are 2 types of Quality of Service Solutions:
1. Stateless solution: Here, the server is not required to keep or store the server
information or session details to itself. The routers maintain no fine-grained state
about traffic, one positive factor of this is, that it's scalable and robust. But also, it
has weak services as there is no guarantee about the kind of performance delay in
a particular application which we encounter. In the stateless solution, the server and
client are loosely coupled and can act.
2. Stateful solution: Here, the server is required to maintain the current state and
session information, the routers maintain per-flow state as the flow is very
important in providing the Quality-of-Service which is providing powerful services
such as guaranteed services and high resource utilization, provides protection, and is
much less scalable and robust. Here, the server and client are tightly bounded.
Quality of Service Parameters:
QoS can be measured quantitatively by using several parameters

10
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

 Packet loss: it happens when the network links become congested and the routers and
switches start dropping the packets. When these packets are dropped during real-time
communication, such as audio or video, these sessions can experience jitter and gaps
in speech.
 Jitter: occurs as the result of network congestion, timing drift, and route changes.
And also, too much jitter can degrade the quality of audio communication.
 Latency: is the time delay, which is taken by a packet to travel from its source to its
destination. For a great system, latency should be as low as possible, ideally, it should
be close to zero.
 Bandwidth: is the capacity of a network channel to transmit maximum possible data
through the channel in a certain amount of time. QoS optimizes a network by
managing its bandwidth and setting the priorities for those applications which require
more resources as compared to other applications.
 Mean opinion score: it is a metric for rating the audio quality which uses a five-point
scale, with a five indicating the highest or best quality.
Implementing Quality of Service:
We can implement Quality of service through three of the following existing models:
1. Best Effort: if we are applying this model then, it means that we are prioritizing all
the data packets equally. But since we all setting the priority order like this, then there
is no guarantee that all the data packets will be delivered, but it will put up the best
effort to deliver all of them. Point to remember is, that the best-effort model is applied
when networks haven’t configured with the QoS policies or incase their network
infrastructure does not support QoS.
2. Integrated Services: or IntServ, this QoS model reserves the bandwidth along a
specific path on the network. The applications ask the network's resource reservation
for themselves and parallelly the network devices monitor the flow of packets to make
sure network resources can accept packets. Point to remember: while implementing
Integrated Services Model, the IntServ-capable routers and resource reservation
protocol are necessary. This model has limited scalability and high consumption of
the network resources.
3. Differentiated Services: in this QoS model, the network elements such as routers and
switches are configured to serve multiple categories of traffic with different priority
orders. A company can categorize the network traffic based on its requirements. Eg.
Assigning higher priority to audio traffic etc.
11
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Difference between Integrated Services and Differentiated Services:

Integrated Services Differentiated Services

This Architecture mainly specifies a simple and


This Architecture mainly specifies
scalable mechanism for classifying and managing
the elements to guarantee Quality of
the traffic of the network and also provides QoS
Service (QoS) on the network.
on the modern IP networks.

These services mainly involve the


These services mark the packets with the priority
prior reservation of the resources
and then sends it to the network and there is no
before sending in order to achieve
concept of prior reservation.
Quality of Service.

It is also known as IntServ. It is also known as DiffSer.

These are not Scalable These are Scalable.

These involve per flow Setup These involve long term Setup

In this end to end service scope is


In this domain service scope is involved
available.

Protocols in Application Layer


Domain Name System (DNS) in Application Layer
DNS is a hostname for IP address translation service. DNS is a distributed database
implemented in a hierarchy of name servers. It is an application layer protocol for message
exchange between clients and servers.
Requirement: Every host is identified by the IP address but remembering numbers is very
difficult for the people also the IP addresses are not static therefore a mapping is required to
change the domain name to the IP address. So DNS is used to convert the domain name of
the websites to their numerical IP address.
Domain: There are various kinds of DOMAIN:
1. Generic domain: .com(commercial) .edu(educational) .mil(military) .org(non profit
organization) .net(similar to commercial) all these are generic domain.

12
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

2. Country domain .in (india) .us .uk


3. Inverse domain if we want to know what is the domain name of the website. Ip to domain
name mapping. So DNS can provide both the mapping for example to find the ip
addresses of geeksforgeeks.org then we have to type nslookup www.geeksforgeeks.org.
Organization of Domain:

Introduction to Remote Login


Remote Login is a process in which user can login into remote site i.e. computer and
use services that are available on the remote computer. With the help of remote login
a user is able to understand result of transferring result of processing from the remote
computer to the local computer.

Figure – Remote login

It is implemented using Telnet.

13
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Figure – Remote login procedure

Procedure of Remote Login :


1. When the user types something on local computer, then local operating system
accepts character.
2. Local computer does not interpret the characters, it will send them to TELNET
client.
3. TELNET client transforms these characters to a universal character set
called Network Virtual Terminal (NVT) characters and it will pass them to the
local TCP/IP protocol Stack.
4. Commands or text which is in the form of NVT, travel through Internet and it will
arrive at the TCP/IP stack at remote computer.
5. Characters are then delivered to operating system and which later on passed to
TELNET server.
6. Then TELNET server changes that characters to characters which can be
understandable by remote computer.

14
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

7. Remote operating system receives character from a pseudo-terminal driver,


which is a piece of software that pretends that characters are coming from a
terminal.
8. Operating system then passes character to the appropriate application program.

NVT Character Set :


 With NVT Character set, TELNET client translates characters into NVT form and
deliver to network.
 TELNET server translates data and commands from NVT form to the other form
that will be understandable by remote computer.
 NVT uses 2 sets of characters, one for data and other for control. Size of both
characters is 8-bit bytes.
 For data, NVT is an 8-bit character set in which 7 lowest bits are same as ASCII
and highest order bit is 0.
 For control characters, NVT uses an 8-bit character set in which the highest bit is
set to 1.

Figure – NVT Character Set

Simple Mail Transfer Protocol (SMTP)


Email is emerging as one of the most valuable services on the internet today. Most
internet systems use SMTP as a method to transfer mail from one user to another.
SMTP is a push protocol and is used to send the mail whereas POP (post office
protocol) or IMAP (internet message access protocol) are used to retrieve those emails
at the receiver’s side.
SMTP Fundamentals
SMTP is an application layer protocol. The client who wants to send the mail opens a
TCP connection to the SMTP server and then sends the mail across the connection.
The SMTP server is an always-on listening mode. As soon as it listens for a TCP

15
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

connection from any client, the SMTP process initiates a connection through port 25.
After successfully establishing a TCP connection the client process sends the mail
instantly.
SMTP Protocol
The SMTP model is of two types:
1. End-to-end method
2. Store-and- forward method
The end-to-end model is used to communicate between different organizations
whereas the store and forward method is used within an organization. An SMTP client
who wants to send the mail will contact the destination’s host SMTP directly, in order
to send the mail to the destination. The SMTP server will keep the mail to itself until
it is successfully copied to the receiver’s SMTP.
The client SMTP is the one that initiates the session so let us call it client- SMTP and
the server SMTP is the one that responds to the session request so let us call it receiver-
SMTP. The client- SMTP will start the session and the receiver-SMTP will respond
to the request.
Model of SMTP system
In the SMTP model user deals with the user agent (UA), for example, Microsoft
Outlook, Netscape, Mozilla, etc. In order to exchange the mail using TCP, MTA is
used. The user sending the mail doesn’t have to deal with MTA as it is the
responsibility of the system admin to set up a local MTA. The MTA maintains a small
queue of mails so that it can schedule repeat delivery of mails in case the receiver is
not available. The MTA delivers the mail to the mailboxes and the information can
later be downloaded by the user agents.

16
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Both the SMTP-client and SMTP-server should have 2 components:


1. User-agent (UA)
2. Local MTA

Communication between sender and the receiver :

The sender’s user agent prepares the message and sends it to the MTA. The MTA’s
responsibility is to transfer the mail across the network to the receiver’s MTA. To
send mails, a system must have a client MTA, and to receive mails, a system must
have a server MTA.

SENDING EMAIL:

Mail is sent by a series of request and response messages between the client and the
server. The message which is sent across consists of a header and a body. A null line
is used to terminate the mail header and everything after the null line is considered as
the body of the message, which is a sequence of ASCII characters. The message body
contains the actual information read by the receipt.

17
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

RECEIVING EMAIL:
The user agent at the server-side checks the mailboxes at a particular time of intervals.
If any information is received, it informs the user about the mail. When the user tries
to read the mail it displays a list of emails with a short description of each mail in the
mailbox. By selecting any of the mail users can view its contents on the terminal.
Some SMTP Commands:
 HELO – Identifies the client to the server, fully qualified domain name, only sent
once per session
 MAIL – Initiate a message transfer, fully qualified domain of originator
 RCPT – Follows MAIL, identifies an addressee, typically the fully qualified name
of the addressee, and for multiple addressees use one RCPT for each addressee
 DATA – send data line by line
Advantages of SMTP:
 If necessary, the users can have a dedicated server.
 It allows for bulk mailing.
 Low cost and wide coverage area.
 Offer choices for email tracking.
 reliable and prompt email delivery.
Disadvantages of SMTP:
 SMTP’s common port can be blocked by several firewalls.
 SMTP security is a bigger problem.
 Its simplicity restricts how useful it can be.
 Just 7 bit ASCII characters can be used.
 If a message is longer than a certain length, SMTP servers may reject the entire
message.
 Delivering your message will typically involve additional back-and-forth
processing between servers, which will delay sending and raise the likelihood that
it won’t be sent.

File Transfer Protocol (FTP) in Application


Layer
18
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

File Transfer Protocol (FTP) is an application layer protocol that is used to transfer the files
between the local devices (PC, smartphone, etc.) to a server. It transfers both text and binary
files over the Internet.
 FTP opens two connections between the computers − one for
the commands and replies (control connection) and a second one for data transfers (data
connection).
 FTP is built on a client-server model architecture using the control connection and data
connection between the client and server.

Control Connection
A Contol Connectcion is established on Port number 21. It is the primary connection and is
used to send commands back and forth between the client and the server. It is used for sending
the control information like user identification, password, and remote directory, etc., once the
control connection is established.

Data Connection
Data Connection is initiated on Port number 20. Using the established Control Connection, the
client and server will create a separate Data Connection to transfer the requested data.
The Data Connection stays open until the transfer is complete, after that the Data Connection
is closed.
Data Connections are closed by either the client or the server, depending on which party is
sending the information. When a client is retrieving data from a server, the server will close
the connection once all the data has been transferred. When the client is transferring data to
the server, the client will terminate the connection after all the data has been transferred.

19
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

FTP transfers files in three different modes –

 Stream mode − Here, the FTP handles the data as a string of bytes without separating
boundaries.
 Block mode − In the block mode, the FTP decomposes the entire data into different
blocks of data.
 Compressed mode − In this mode, the FTP uses the Lempel-Ziv algorithm to compress
the data.

World Wide Web (WWW)


The World Wide Web is abbreviated as WWW and is commonly known as the web. The
WWW was initiated by CERN (European library for Nuclear Research) in 1989.
WWW can be defined as the collection of different websites around the world, containing
different information shared via local servers(or computers).
History:
It is a project created, by Timothy Berner Lee in 1989, for researchers to work together
effectively at CERN. is an organization, named the World Wide Web Consortium (W3C),
which was developed for further development of the web. This organization is directed by
Tim Berner’s Lee, aka the father of the web.
System Architecture:
From the user’s point of view, the web consists of a vast, worldwide connection of documents
or web pages. Each page may contain links to other pages anywhere in the world. The pages
can be retrieved and viewed by using browsers of which internet explorer, Netscape
20
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Navigator, Google Chrome, etc are the popular ones. The browser fetches the page requested
interprets the text and formatting commands on it, and displays the page, properly formatted,
on the screen.
The basic model of how the web works are shown in the figure below. Here the browser is
displaying a web page on the client machine. When the user clicks on a line of text that is
linked to a page on the abd.com server, the browser follows the hyperlink by sending a
message to the abd.com server asking it for the page.

Here the browser displays a web page on the client machine when the user clicks on a line of
text that is linked to a page on abd.com, the browser follows the hyperlink by sending a
message to the abd.com server asking for the page.
Working of WWW:
The World Wide Web is based on several different technologies: Web browsers, Hypertext
Markup Language (HTML) and Hypertext Transfer Protocol (HTTP).
A Web browser is used to access web pages. Web browsers can be defined as programs which
display text, data, pictures, animation and video on the Internet. Hyperlinked resources on
the World Wide Web can be accessed using software interfaces provided by Web browsers.
Initially, Web browsers were used only for surfing the Web but now they have become more
universal. Web browsers can be used for several tasks including conducting searches,
mailing, transferring files, and much more. Some of the commonly used browsers are Internet
Explorer, Opera Mini, and Google Chrome.

21
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Features of WWW:
 HyperText Information System
 Cross-Platform
 Distributed
 Open Standards and Open Source
 Uses Web Browsers to provide a single interface for many services
 Dynamic, Interactive and Evolving.
 “Web 2.0”

Components of the Web: There are 3 components of the web:


Uniform Resource Locator (URL): serves as a system for resources on the web.
1. HyperText Transfer Protocol (HTTP): specifies communication of browser and
server.
2. Hyper Text Markup Language (HTML): defines the structure, organisation and
content of a webpage.

The Hypertext Transfer Protocol (HTTP)


The Hypertext Transfer Protocol (HTTP) is an application-level protocol for distributed,
collaborative, hypermedia information systems. This is the foundation for data communication
for the World Wide Web (i.e. internet) since 1990. HTTP is a generic and stateless protocol
which can be used for other purposes as well using extensions of its request methods, error
codes, and headers.
Basically, HTTP is a TCP/IP based communication protocol, that is used to deliver data
(HTML files, image files, query results, etc.) on the World Wide Web. The default port is TCP
80, but other ports can be used as well. It provides a standardized way for computers to
communicate with each other. HTTP specification specifies how clients' request data will be
constructed and sent to the server, and how the servers respond to these requests.

Basic Features
There are three basic features that make HTTP a simple but powerful protocol:
 HTTP is connectionless: The HTTP client, i.e., a browser initiates an HTTP request
and after a request is made, the client waits for the response. The server processes the
request and sends a response back after which client disconnect the connection. So client

22
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

and server knows about each other during current request and response only. Further
requests are made on new connection like client and server are new to each other.
 HTTP is media independent: It means, any type of data can be sent by HTTP as long
as both the client and the server know how to handle the data content. It is required for
the client as well as the server to specify the content type using appropriate MIME-type.
 HTTP is stateless: As mentioned above, HTTP is connectionless and it is a direct result
of HTTP being a stateless protocol. The server and client are aware of each other only
during a current request. Afterwards, both of them forget about each other. Due to this
nature of the protocol, neither the client nor the browser can retain information between
different requests across the web pages.

Basic Architecture
The following diagram shows a very basic architecture of a web application and depicts where
HTTP sits:

The HTTP protocol is a request/response protocol based on the client/server based architecture
where web browsers, robots and search engines, etc. act like HTTP clients, and the Web server
acts as a server.

23
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Client
The HTTP client sends a request to the server in the form of a request method, URI, and
protocol version, followed by a MIME-like message containing request modifiers, client
information, and possible body content over a TCP/IP connection.
Server
The HTTP server responds with a status line, including the message's protocol version and a
success or error code, followed by a MIME-like message containing server information, entity
meta information, and possible entity-body content.

Post Office Protocol, Version 3 (POP3)


Post Office Protocol version 3 (POP3) is a standard protocol used by email clients to retrieve
email messages from a mail server. It is a simple, text-based protocol that allows a client to
connect to a server, retrieve email messages, and mark them as read or unread.
POP3 works by establishing a connection between the email client and the mail server. The
client sends a request to the server to retrieve email messages, and the server responds with a
list of available messages. The client can then choose which messages to download and mark
as read or unread. Once the client has finished retrieving messages, the connection is closed.
POP3 is a widely used protocol for accessing email, but it has some limitations.It does not
support real-time synchronization of email messages between the client and server, so the
client must manually check for new messages. It also does not support multiple devices
accessing the same email account simultaneously,as each device will have its own copy of the
email messages.
There are newer protocols available, such as IMAP (Internet Message Access Protocol), which
offer more advanced features and support for real-time synchronization and multiple device
access. However, POP3 remains a popular choice for email clients due to its simplicity and
widespread support.

POP3 and Email Applications


Many email applications support POP3, including popular desktop email clients like Microsoft
Outlook and Mozilla Thunderbird, as well as mobile email apps like Apple Mail and Gmail.
These applications allow users to configure their email accounts to use POP3, either as the

24
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

primary protocol for retrieving email or as a secondary option in addition to other protocols
like IMAP (Internet Message Access Protocol).
When using POP3 with an email application, users typically enter their email address,
password, and the server and port information for their email account. The email application
then establishes a connection to the server using POP3 and retrieves the email messages, which
are downloaded to the client and stored locally. Users can then read and manage their email
messages directly in the email application.
POP3 has some limitations compared to other protocols like IMAP, including the lack of real-
time synchronization and support for multiple device access. However, it remains a popular
choice for many users due to its simplicity and widespread support.

POP3 Ports
It uses two network ports for communication −port 110 for unencrypted connections and port
995 for encrypted connections using SSL/TLS (Secure Sockets Layer/Transport Layer
Security).
When configuring an email account in an email client, users may need to specify the POP3
port number to use. The default port for unencrypted POP3 connections is 110, and the default
port for encrypted POP3 connections using SSL/TLS is 995. Some email servers may use
different port numbers for POP3, in which case the user will need to enter the correct port
number when configuring their email account.
It is important to note that using an encrypted connection (port 995) is generally recommended
for security reasons. Unencrypted connections (port 110) are vulnerable to interception and
may not be suitable for sensitive data.

POP3 Operation
It operates by establishing a connection between the email client and the mail server and
exchanging a series of commands and responses to perform various tasks.
Here is an overview of how POP3 operates −
 The email client establishes a connection to the mail server using the POP3 protocol.
 The client sends a request to the server, asking for a list of available email messages.
 The server responds with a list of messages, including their size and unique identifier.
 The client selects which messages to retrieve and sends a request to the server to
download them.
 The server sends the requested messages to the client, and marks them as read or unread
depending on the client's preference.

25
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

 The client can also send commands to delete messages from the server, or to mark them
as read or unread.
 Once the client has finished retrieving messages, it sends a request to the server to close
the connection. The server responds with an acknowledgment, and the connection is
closed.
POP3 is a simple protocol that allows email clients to retrieve and manage email messages
from a mail server. It does not support real-time synchronization of email messages between
the client and server, so the client must manually check for new messages. It also does not
support multiple devices accessing the same email account simultaneously, as each device will
have its own copy of the email messages. There are newer protocols available, such as IMAP
(Internet Message Access Protocol), which offer more advanced features and support for real-
time synchronization and multiple device access.

Advantages and Limitations of POP3


It has several advantages, as well as some limitations.
Some advantages of POP3 include −
 Simplicity − POP3 is a simple, text-based protocol that is easy to implement and
understand.
 Widespread support − POP3 is supported by many email clients and servers, making
it a widely used and widely compatible protocol.
 Efficient storage − POP3 downloads email messages to the client, allowing users to
store their email locally on their device. This can be more efficient than storing email
messages on the server, especially if the user has a large number of messages.

However, POP3 also has some limitations, including −


 Lack of real-time synchronization − POP3 does not support real-time synchronization
of email messages between the client and server. This means that the client must
manually check for new messages, rather than receiving them in real-time.
 Limited device access − POP3 does not support multiple devices accessing the same
email account simultaneously. Each device will have its own copy of the email
messages, and changes made on one device will not be reflected on other devices.
 Security concerns − POP3 does not support encrypted connections by default, and
unencrypted connections are vulnerable to interception.

26
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

Multi-Purpose Internet Mail Extensions


MIME represents Multi-Purpose Internet Mail Extensions. It is a development to the
Internet email protocol that enables its users to exchange several kinds of data files over the
Internet, including images, audio, and video.
The MIME is required if the text in character sets other than the American Standard Code for
Information Interchange (ASCII). Virtually, all human-written Internet email and a fairly large
proportion of automated email is transmitted via Simple Mail Transfer Protocol (SMTP) in
MIME format.
MIME was designed mainly for SMTP, but the content types defined by MIME standards are
important also in communication protocols outside of email, such as Hypertext Transfer
Protocol (HTTP).
MIME Header
There are five header fields represented in MIME which are as follows −
 MIME-version − It denotes the MIME version being used. The current version is 1.1.
It is defined as MIME-version: 1.1.
 Content-type − It defines the type and subtype of the data in the body of the message.
The content type and content subtype are divided by a slash. This field defines how the
object in the body is to be executed. The default value is plaintext in US ASCII.
The content-type field is represented as follows −
Context-type: <type/subtype; parameters>
 Content-transfer encoding − It defines how the object inside the body has been
encoded to US ASCII to create it acceptable for mail transfer. Thus, it determines the
method used to encode the message into 0s and 1s for transport.
The content transfer encoding field is represented as follows −
Content-transfer-encoding : <type>
 Content-Description − This field tells what the message is. It is the form of ASCII
recipient will know whether it is worth decoding and reading the message.
 Content-ID − This field identifies the contents. Its format is the same as the format of
the standard Message-Id header.

Simple Network Management Protocol


SNMP stands for Simple Network Management Protocol. It is an Internet-standard protocol
for handling devices on IP networks. Devices that typically provide SNMP include routers,

27
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

switches, servers, workstations, printers, modem racks, and more. It is used mainly in the
network management framework to monitor network-attached computers for conditions
requiring regulatory attention.
It is a framework for managing devices on the Internet using the TCP-IP protocol suite. It
supports a set of fundamental operations for monitoring and maintaining the Internet.

SNMP Concept
SNMP facilitates the concept of manager and agent. A manager, generally a host, controls and
monitors a group of agents, usually routers. This is an application-level protocol in which some
manager stations control a group of agents. The protocol is designed to monitor different
manufacturer’s devices and installed on various physical networks at the application level.

Managers and Agents


A management station, known as a manager. It is a host that runs the SNMP user program. A
managed station was known as an agent. It is a router (or a host) that runs the SNMP server
program. Management is completed through simple interaction between a manager and an
agent. The agent keeps performance data in a database. The manager has created the values in
the database.

Components of SNMP
An SNMP-managed network includes three key components. These components are as
follows −
 Managed Device − It is a network node that executes an SNMP interface that enables
unidirectional (read-only) or bidirectional access to node-specific information.
 Agent − An agent is a network-management software mechanism that consists of a
managed device. An agent has local knowledge of management data and translates that
information to or from an SNMP specific form.
 Network management system (NMS) − A network management system (NMS)
executes applications that monitor and control managed devices.

SNMP Protocols
SNMP uses two other protocols which are as follows –
SMI- SMI stands for Structure Management Information. SMI represents the general
rules for naming objects, defining object types (including range and length), and showing how
to encode objects and values.

28
St. Joseph’s College of Engineering
IT1401 Computer Communication Dept. of IT 2022-2023

SMI does not determine the number of objects an entity should handle or name the objects to
be managed or define the relationship between the objects and their values.
MIB
MIB stands for Management information base. For each entity to be handled, this protocol
must represent the number of objects, name them as per the rules represented by SMI, and
relate a type to each named object. MIB generates a collection of named objects, their types,
and their relationships to each other in an entity to be managed.

29
St. Joseph’s College of Engineering

You might also like