0% found this document useful (0 votes)
182 views

4 - Internet Protocols and Standards - HTTP, HTTPS, FTP, SMTP, TCP - IP, URI & URL

Uploaded by

anuj9262
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
182 views

4 - Internet Protocols and Standards - HTTP, HTTPS, FTP, SMTP, TCP - IP, URI & URL

Uploaded by

anuj9262
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 67

Internet Protocols and Standards:

HTTP, HTTPS, FTP, SMTP, TCP/IP,


URI & URL
Internet Protocol

• Internet Protocol (IP) – a set of rules that dictate how data should be
delivered over the public network (Internet)
• IP - set of rules, for routing and addressing packets of data so that they can
travel across networks and arrive at the correct destination.
• Data traversing the Internet is divided into smaller pieces, called packets.
IP information is attached to each packet, and this information
helps routers to send packets to the right place.
• Every device or domain that connects to the Internet is assigned an IP
address.
• Once the packets arrive at their destination, they are handled differently
depending on which transport protocol is used in combination with IP. The
most common transport protocols are TCP and UDP (User Datagram
Protocol).
Internet Standard

• Internet Standards cover interoperability of systems on the Internet through


defining protocols, message formats, schemas, and languages.
• An Internet Standard ensures that hardware and software produced by
different vendors can work together.
• Having a standard makes it much easier to develop software and hardware
that link different networks because software and hardware can be
developed one layer at a time.
• Normally, the standards used in data communication are called protocols.
• Networking standards
– Define the rules for data communications that are needed for
interoperability of networking technologies and processes.
7 layers of Open Systems Interconnection (OSI) Model

Open Systems Interconnection model Application Layer 7


Conceptual model that characterizes Presentation Layer 6
and standardizes the communication Session Layer 5

7 layers of Open Systems Interconnection (OSI) Model


Transport Layer 4
functions of a telecommunication or
Network Layer 3
computing system without regard to its Data Link Layer 2
underlying internal structure and Physical Layer 1
technology.
All People Seem To Need Data Processing /
Please Do Not Tell Secrets to Personal
Assistant
OSI Model
Data unit Layer Function
7. Application User interface (Browser)
Data representation, encryption and decryption, convert
Data 6. Presentation
Host machine dependent data to machine independent data
5. Session Set up, monitor and terminate the connection session
Segments 4. Transport Flow control (TCP, UDP)
Packet/ Path determination, Addressing, routing and delivery of
3. Network
Datagram datagrams between points on a network. (IP Address)
Media
Bit/Frame 2. Data link A reliable direct point-to-point data connection.
Bit 1. Physical Media, signal and binary transmission
Layer 7 – Application layer

• This is the closest layer to the end user.


• It provides the interface between the applications we use and the
underlying layers. But notice that the programs you are using (like a web
browser – IE, Firefox or Opera…) do not belong to Application layer.
Telnet, FTP, email client – simple mail (SMTP), Hypertext Transfer
Protocol (HTTP) are examples of Application layer.

Layer 6 – Presentation layer


• This layer ensures the presentation of data, that the communications
passing through are in the appropriate form for the recipient. In general, it
acts as a translator of the network.
• For example, you want to send an email and the Presentation will format
your data into email format. Or you want to send photos to your friend, the
Presentation layer will format your data into GIF, JPG or PNG format.
Layer 5 – Session layer

• Establishes, maintains and ends communication with the receiving device.

Layer 4 – Transport layer


• This layer maintains flow control of data and provides for error checking
and recovery of data between the devices.
• The most common example of Transport layer is Transmission Control
Protocol (TCP) and User Datagram Protocol (UDP).

Layer 3 – Network layer


• This layer provides logical addresses which routers will use to determine
the path to the destination.
• In most cases, the logic addresses here means the IP addresses (including
source & destination IP addresses).
Layer 2 – Data Link Layer
• The Data Link layer formats the message into a data frame, and adds a
header containing the hardware destination and source address to it. This
header is responsible for finding the next destination device on a local
network.
• Notice that layer 3 is responsible for finding the path to the last destination
(network) but it doesn’t care about who will be the next receiver. It is the
Layer 2 that helps data to reach the next destination.
• This layer is subdivide into 2 sub-layers: logical link control (LLC) and
media access control (MAC).
• The LLC functions include:
– Managing frames to upper and lower layers
– Error Control
– Flow control
• The MAC sublayer carries the physical address of each device on the
network. This address is more commonly called a device’s MAC address.
MAC address is a 48 bits address which is burned into the NIC card on the
device by its manufacturer.
Layer 1 – Physical layer

• The Physical Layer defines the physical characteristics of the network such
as connections, voltage levels and timing.
Hypertext Transfer Protocol
Development of HTTP

• Initiated by Tim Berners-Lee at CERN in 1989.


• Development of early HTTP Requests for Comments (RFCs) was a
coordinated effort by the Internet Engineering Task Force (IETF) and the
World Wide Web Consortium (W3C), with work later moving to the IETF.
• HTTP v1 was first documented (as version 1.1) in 1997.
• HTTP v2 is a more efficient expression of HTTP's semantics "on the wire",
and was published in 2015. Supported by virtually all web browsers and
major web servers.
• HTTP v3 is the proposed successor to HTTP v2 - 2020
An overview of HTTP

• Hypertext Transfer Protocol (HTTP) is an application-layer protocol for


transmitting hypermedia documents, such as HTML.
• Due to its extensibility, it is used to not only fetch hypertext documents,
but also images and videos or to post content to servers, like with HTML
form results.
• HTTP follows a classical client-server model, with a client opening a
connection to make a request, then waiting until it receives a response.
• It is the foundation of any data exchange on the Web and it is a client-
server protocol, which means requests are initiated by the recipient, usually
the Web browser.
• A complete document is reconstructed from the different sub-documents
fetched, for instance text, layout description, images, videos, scripts, and
more.
• HTTP is a stateless protocol, meaning that the server does not keep any
data (state) between two requests. Though often based on a TCP/IP layer, it
can be used on any reliable transport layer.
Clients and servers

• Clients and servers communicate by exchanging individual messages (as


opposed to a stream of data).
• The messages sent by the client, usually a Web browser, are
called requests and the messages sent by the server as an answer are
called responses.
Client: the user-agent

• The user-agent is any tool that acts on the behalf of the user. This role is
primarily performed by the Web browser.
• The browser initiate the request. It is never the server (though some
mechanisms have been added over the years to simulate server-initiated
messages).
• To present a Web page, the browser sends an original request to fetch the
HTML document that represents the page. It then analyzes this file, making
additional requests corresponding to execution scripts, layout information
(CSS) to display, and sub-resources contained within the page (usually images
and videos).
• The Web browser then mixes these resources to present to the user a complete
document, the Web page. Scripts executed by the browser can fetch more
resources in later phases and the browser updates the Web page accordingly.
• A Web page is a hypertext document. This means some parts of displayed text
are links which can be activated (usually by a click of the mouse) to fetch a
new Web page, allowing the user to direct their user-agent and navigate through
the Web.
The Web server

• On the opposite side of the communication channel, is the server,


which serves the document as requested by the client.
• A server appears as only a single machine virtually: this is because it may
actually be a collection of servers, sharing the load (load balancing) or a
complex piece of software interrogating other computers (like cache, a DB
server, or e-commerce servers), totally or partially generating the document
on demand.
URL beginning with the HTTP scheme
and the WWW domain name label
Example

• HTTP functions as a request–response protocol in the client–server


computing model.
1. A web browser, for example, may be the client and an application running
on a computer hosting a website may be the server. The client submits an
HTTP request message to the server. The server, which provides resources
such as HTML files and other content, or performs other functions on
behalf of the client, returns a response message to the client. The response
contains completion status information about the request and may also
contain requested content in its message body.
2. A client, for example, may be a home computer, laptop, or mobile device.
The HTTP server is typically a web host running web server software,
such as Apache or IIS (Internet Information Services).
HTTPS
HTTPS

• HTTPS stands for Hyper Text Transfer Protocol Secure.


• It is a protocol for securing the communication between two systems e.g.
the browser and the web server.
• Secure version of the HTTP protocol that uses the SSL/TLS protocol for
encryption and authentication.
• The HTTPS protocol makes it possible for website users to transmit
sensitive data such as credit card numbers, banking information, and login
credentials securely over the internet.
• For this reason, HTTPS is especially important for securing online
activities such as shopping, banking, and remote work.
• Hypertext transfer protocol secure (HTTPS) is the secure version of HTTP,
which is the primary protocol used to send data between a web browser
and a website.
How is HTTPS different from HTTP?

• HTTPS adds
1. Encryption
2. Authentication
3. Integrity to the HTTP protocol
How is HTTPS different from HTTP?

1. Encryption
– HTTP was originally designed as a clear text protocol, it is vulnerable
to eavesdropping (spying) and man in the middle attacks.
– By including SSL/TLS encryption, HTTPS prevents data sent over the
internet from being interrupted and read by a third party.
– Through public-key cryptography and the SSL/TLS handshake, an
encrypted communication session can be securely set up between two
parties who have never met in person (e.g. a web server and browser)
via the creation of a shared secret key.
How is HTTPS different from HTTP?

2. Authentication
• Unlike HTTP, HTTPS includes robust authentication via the SSL/TLS
protocol.
• A website’s SSL/TLS certificate includes a public key that a web browser
can use to confirm that documents sent by the server (such as HTML
pages) have been digitally signed by someone in possession of the
corresponding private key.
• HTTPS websites can also be configured for mutual authentication, in
which a web browser presents a client certificate identifying the user.
• Mutual authentication is useful for situations such as remote work, where it
is desirable to include multi-factor authentication, reducing the risk of
phishing or other attacks involving credential theft.
How is HTTPS different from HTTP?

3) Integrity
• Each document (such as a web page, image, or JavaScript file) sent to a
browser by an HTTPS web server includes a digital signature that a web
browser can use to determine that the document has not been altered by a
third party or otherwise corrupted while in transit.
• The server calculates a cryptographic hash of the document’s contents,
included with its digital certificate, which the browser can independently
calculate to prove that the document’s integrity is intact.
Why use HTTPS?

Integrity and Authentication


• Through encryption and authentication, HTTPs protects the integrity of
communication between a website and a user’s browsers.
• Users will know that the data sent from your web server has not been
intercepted and/or altered by a third party in transit.

Privacy
• HTTPs plays an important role to avoid -
– Intruders scooping up credit card numbers and passwords (shop or
bank online)
– Avoid snooping (including governments, employers, or someone
building a profile to de-anonymize your online activities)
Why use HTTPS?

User Experience
• Provide secured website
• Great user experience
Compatibility
• Current browser changes are pushing HTTP ever closer to incompatibility.
• Mozilla Firefox recently announced an optional HTTPs-only mode, while
Google Chrome is steadily moving to block mixed content (HTTP resources
linked to HTTPs pages).
SEO
• Search engines (including Google) use HTTPs as a ranking signal when
generating search results.
• Website owners can get an easy SEO boost just by configuring web servers to
use HTTPs rather than HTTP.
What happens if my website doesn’t use
HTTPs?
• In 2020, websites that do not use HTTPs or serve mixed content (serving
resources like images via HTTP from HTTPs pages) are subject to browser
security warnings and errors.
• Furthermore, these websites unnecessarily compromise their users’ privacy
and security, and are not preferred by search engine algorithms.
• Therefore, HTTP and mixed-content websites can expect more browser
warnings and errors, lower user trust and poorer SEO than if they had
enabled HTTPs.
How do I know if a website uses HTTPS?

• An HTTPs URL begins with https:// instead of http:// Modern web


browsers also indicate that a user is visiting a secure HTTPs website by
displaying a closed padlock symbol to the left of the URL.

• In modern browsers like Chrome, Firefox, and Safari, users can click the
lock to see if an HTTPs website’s digital certificate includes identifying
information about its owner.
FTP
File Transfer Protocol
FTP

• FTP
– File transfer protocol.
– Network protocol for transmitting files between computers over
TCP/IP connections.
• FTP is an application layer protocol.
• In an FTP transaction
– The end user's computer is called the local host.
– The second computer involved in FTP is a remote host, which is
usually a server.
• Both computers need to be connected via a network and configured
properly to transfer files via FTP. Servers must be set up to run FTP
services, and the client must have FTP software (FileZilla, Progress
MOVEit, WinSCP, etc.) installed to access these services.
• Used for transferring the web page files from server to client.
• Used for downloading the files to computer from other servers.
How does FTP work?

• FTP is a client-server protocol that relies on two communications channels


between the client and server:
– A command channel for controlling the conversation
– A data channel for transmitting file content.
• Working of FTP
– A user typically needs to log on to the FTP server, although some
servers make some or all of their content available without a login, a
model known as anonymous FTP.
– The client initiates a conversation with the server when the user
requests to download a file.
– Using FTP, a client can upload, download, delete, rename, move and
copy files on a server.
How does FTP work?

• FTP sessions work in active or passive modes:


– Active mode
• After a client initiates a session via a command channel request,
the server creates a data connection back to the client and begins
transferring data.
– Passive mode
• The server uses the command channel to send the client the
information it needs to open a data channel. Because passive mode
has the client initiating all connections, it works well across
firewalls and network address translation gateways.
Why FTP?

• Transferring files from one system to another is very simple and


straightforward, but sometimes it can cause problems.
• Example
– Two systems may have different file conventions.
– Two systems may have different ways to represent text and data.
– Two systems may have different directory structures.

• FTP protocol overcomes these problems by establishing two connections


between hosts.
– One connection is used for data transfer
– Another connection is used for the control connection
Mechanism of FTP

• The above shows the basic model of the FTP.


• The FTP client has three components: the user interface, control process, and
data transfer process.
• The server has two components: the server control process and the server data
transfer process.
Two types of connections in FTP

• Control Connection
– Uses very simple rules for communication.
– Can transfer a line of command or line of response
at a time.
– Is made between the control processes.
– Remains connected during the entire interactive FTP
session.
• Data Connection
– Uses very complex rules as data types may vary.
– Is made between data transfer processes.
– The data connection opens when a command comes
for transferring the files and closes when the file is
transferred.
FTP Used

• FTP is used for file transfers between one system and another, and it has
several common use cases, including the following:
• Backup
– FTP can be used by backup services or individual users to backup data
from one location to a secured backup server running FTP services.
• Replication
– Similar to backup, replication involves duplication of data from one
system to another but takes a more comprehensive approach to provide
higher availability and resilience.
• Access and data loading
– FTP is also commonly used to access shared web hosting and cloud
services as a mechanism to load data onto a remote system.
Advantages of FTP

• Speed
– One of the biggest advantages of FTP is speed.
– The FTP is one of the fastest way to transfer the files from one
computer to another computer.
• Efficient
– It is more efficient as we do not need to complete all the operations to
get the entire file.
• Security
– To access the FTP server, we need to login with the username and
password. Therefore, we can say that FTP is more secure.
• Back & forth movement
– FTP allows us to transfer the files back and forth. Suppose you are a
manager of the company, you send some information to all the
employees, and they all send information back on the same server.
Disadvantages of FTP

• The standard requirement of the industry is that all the FTP transmissions
should be encrypted. However, not all the FTP providers are equal and not
all the providers offer encryption. So, we will have to look out for the FTP
providers that provides encryption.
• FTP serves two operations, i.e., to send and receive large files on a
network. However, the size limit of the file is 2GB that can be sent. It also
doesn't allow to run simultaneous transfers to multiple receivers.
• Passwords and file contents are sent in clear text that allows unwanted
spying. So, it is quite possible that attackers can carry out the brute force
attack by trying to guess the FTP password.
• It is not compatible with every system.
SMTP
(Simple Mail Transfer Protocol)
SMTP

• SMTP - Simple Mail Transfer Protocol.


• SMTP is a set of communication guidelines that allow software to transmit
an electronic mail over the internet is called Simple Mail Transfer
Protocol.
• It is a program used for sending messages to other computer users based
on e-mail addresses.
• It provides a mail exchange between users on the same or different
computers, and it also supports:
– Sending a single message to one or more recipients.
– Sending message can include text, voice, video or graphics.
– Send the messages on networks outside the internet.
SMTP

• Using a process called “store and forward,” SMTP moves email on and
across networks.
• It works closely with the Mail Transfer Agent (MTA) to send
communication to the right computer and email inbox.
• The main purpose of SMTP is used to set up communication rules between
servers. The servers have a way of identifying themselves and announcing
what kind of communication they are trying to perform. They also have a
way of handling the errors such as incorrect email address.
• For example, if the recipient address is wrong, then receiving server reply
with an error message of some kind.
Model of SMTP system
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 users sending
the mail do not have to deal with the MTA it is the responsibility of the
system admin to set up the local MTA.
• The MTA maintains a small queue of mails so that it can schedule repeat
delivery of mail 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.

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


– User agent (UA)
– Local MTA
Communication between sender and the
receiver
• The senders, user agent prepare the message and send it to the MTA.
• The MTA functioning is to transfer the mail across the network to the
receivers MTA. To send mail, a system must have the client MTA, and to
receive mail, a system must have a server MTA.
• Sending Email
– Mail is sent by a series of request and response messages between the
client and a server. The message which is sent across consists of a
header and the body. A null line is used to terminate the mail header.
The message body contains the actual information read by the receipt.
• 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
mails with a short description of each mail in the mailbox. By selecting
any of the mail user can view its contents on the terminal.
TCP / IP
Transmission Control
Protocol / Internet Protocol
Transmission Control Protocol (TCP)

• TCP - Transmission Control Protocol.


• It is a transport layer protocol that facilitates the transmission of packets
from source to destination.
• It is a connection-oriented protocol that means it establishes the connection
prior to the communication that occurs between the computing devices in a
network.
• This protocol is used with an IP protocol, so together, they are referred to
as a TCP/IP.
• The main functionality of the TCP is to take the data from the application
layer. Then it divides the data into a several packets, provides numbering to
these packets, and finally transmits these packets to the destination.
• TCP is a connection-oriented protocol, so the connection will remain
established until the communication is not completed between the sender
and the receiver.
Features of TCP protocol

Transport Layer Protocol


• TCP is a transport layer protocol as it is used in transmitting the data from
the sender to the receiver.
Reliable
• TCP is a reliable protocol as it follows the flow and error control
mechanism. It also supports the acknowledgment mechanism, which
checks the state and sound arrival of the data.
Order of the data is maintained
• This protocol ensures that the data reaches the intended receiver in the
same order in which it is sent.
• It orders and numbers each segment so that the TCP layer on the
destination side can reassemble them based on their ordering.
Features of TCP protocol

Connection-oriented
• It is a connection-oriented service that means the data exchange occurs
only after the connection establishment. When the data transfer is
completed, then the connection will get terminated.
Full duplex
• It is a full-duplex means that the data can transfer in both directions at the
same time.
Stream-oriented
• TCP is a stream-oriented protocol as it allows the sender to send the data in
the form of a stream of bytes and also allows the receiver to accept the data
in the form of a stream of bytes.
Working of TCP

• In TCP, the connection is established by using three-way handshaking.


– The client sends the segment with its sequence number.
– The server, in return, sends its segment with its own sequence number
– Acknowledgement sequence, which is one more than the client
sequence number.
• When the client receives the acknowledgment of its segment, then it sends
the acknowledgment to the server. In this way, the connection is
established between the client and the server.
Internet Protocol (IP)

• IP - internet protocol.
• It is a protocol used for sending the packets from source to destination.
• The main task of IP is to deliver the packets from source to the destination
based on the IP addresses available in the packet headers.
• IP defines the packet structure that hides the data which is to be delivered
as well as the addressing method that labels the datagram with a source and
destination information.
• An IP protocol provides the connectionless service, which is accompanied
by two transport protocols, i.e., TCP/IP and UDP/IP, so internet protocol is
also known as TCP/IP or UDP/IP.
Function of Internet Protocol (IP)

• The main function of the internet protocol is to provide addressing to the


hosts, encapsulating the data into a packet structure, and routing the data
from source to the destination across one or more IP networks.
• In order to achieve these functionalities, internet protocol provides two
major things which are given below.
• An internet protocol defines two things
1. Format of IP packet
2. IP Addressing system
1) IP packet

• Before an IP packet is sent over the network, two major components are
added in an IP packet, i.e., header and a payload.
• An IP header contains information about the IP packet which includes -
– Source IP address: The source is the one who is sending the data.
– Destination IP address: The destination is a host that receives the data
from the sender.
– Header length: length of the IP header in 4-byte (32-bit) units known as
“words,” and includes any option fields present and padding needed to
align the header on a 32-bit boundary.
– Packet length: Includes the IP addresses of the source and destination,
plus other fields that help to route the packet.
– TTL (Time to Live): The number of steps occurs before the packet gets
discarded.
– Transport protocol: The transport protocol used by the internet protocol,
either it can be TCP or UDP.
• Payload: Payload is the data that is to be transported.
2) IP Addressing

• An IP address is a unique identifier assigned to the computer which is


connected to the internet.
• Each IP address consists of a series of characters like 192.168.1.2. Users
cannot access the domain name of each website with the help of these
characters, so DNS resolvers are used that convert the human-readable
domain names into a series of characters.
• Each IP packet contains two addresses, i.e., the IP address of the device,
which is sending the packet, and the IP address of the device which is
receiving the packet.
• Types of IP addresses
a) Public address
b) Private address
2) IP Addressing

a) Public address
• The public address is also known as an external address as they are
grouped under the WAN addresses.
• Can define the public address as a way to communicate outside the
network. This address is used to access the internet.
• The public address available on our computer provides the remote access
to our computer. With the help of a public address, we can set up the home
server to access the internet.
2) IP Addressing

b) Private address
• A private address is also known as an internal address, as it is grouped
under the LAN addresses.
• It is used to communicate within the network. These addresses are not
routed on the internet so that no traffic can come from the internet to this
private address.
• The private addresses are assigned to mainly those computers, printers,
smartphones, which are kept inside the home or the computers that are kept
within the organization.
• Example - a private address is assigned to the printer, which is kept inside
our home, so that our family member can take out the print from the
printer.
Uniform Resource Identifier
(URI)
Uniform Resource Identifier (URI)

• A URI or Uniform Resource Identifier is a string identifier that refers to a


resource on the internet.
• It is a string of characters that is used to identify any resource on
the internet using location, name, or both.
• A URI has two subsets -
– URL (Uniform Resource Locator)
– URN (Uniform Resource Number)
Syntax of URI

• Scheme
– The first component of URI is scheme that contain a sequence of
characters that can be any combination of letter, digit, plus sign, or
hyphen (_), which is followed by a colon (:). The popular schemes
are http, file, ftp, data, and irc. The schemes should be registered
with IANA (Internet Assigned Numbers Authority).
• Authority
– The authority component is optional and preceded by two slashes (//).
It contains three sub-components:
• userinfo: It may contain a username and an optional password
separated by a colon. The sub-component is followed by the @
symbol.
• host: It contains either a registered name or an IP address. The IP
address must be enclosed within [] brackets.
• Port: Optional
Syntax of URI

• Path
– It consists of a sequence of path segments separated by a slash(/). The
URI always specifies it; however, the specified path may be empty or
of 0 lengths.
• Query
– It is an optional component, which is preceded by a question mark(?).
It contains a query string of non-hierarchical data.
• Fragment
– It is also an optional component, preceded by a hash(#) symbol. It
consists of a fragment identifier that provides direction to a secondary
resource.
Some examples of URI

1. mailto:[email protected]
2. news:comp.infosystems.www.servers.unix
3. urn:oasis:names:specification:docbook:dtd:xml:4.1.2
4. foo://example.com:8042/over/there?name=ferret#nose
Uniform Resource Locator (URL)

• A URL or Uniform Resource Locator is used to find the location of the


resource on the web.
• It is a reference for a resource and a way to access that resource.
• A URL always shows a unique resource, and it can be an HTML page, a
CSS document, an image, etc.
• A URL uses a protocol for accessing the resource, which can be HTTP,
HTTPS, FTP, etc.
Uniform Resource Locator (URL)

• URL
– It is mainly referred to as the address of the website, which a user can
find in their address bars.
Syntax of URL

• Each HTTP URL follow the syntax of its generic URI.


• Hence the syntax of the URL is also similar to the syntax of URI.
• The URL is made up of the following components
– Scheme
• The URL's first component is a scheme, which represents a
protocol that a browser must need to use to request the resource.
• The commonly used protocols for websites are HTTP or HTTPS.
– Authority
• The authority includes two sub-components, domain name and
port, separated by a colon. The domain name can be anything, the
registered name of the resource like javatpoint.com, and port is
the technical gate to access the resource on a webserver. The port
number 80 is used for HTTP and 443 is used for HTTPS.
Syntax of URL

– Path
• The path indicates the complete path to the resource on the
webserver. It can be like /software/htp/index.html.
– Query String
• It is the string that contains the name and value pair. If it is used in
a URL, it follows the path component and gives the information.
Such as "?key1=value1&key2=value2".
– Fragment
• It is also an optional component, preceded by a hash(#) symbol. It
consists of a fragment identifier that provides direction to a
secondary resource.
Difference between URI and URL
URI URL
URI is an acronym for Uniform Resource URL is an acronym for Uniform Resource
Identifier. Locator.
URI contains two subsets, URN, which tell URL is the subset of URI, which tells the
the name, and URL, which tells the only location of the resource.
location.
All URIs cannot be URLs, as they can tell All URLs are URIs, as every URL can
either name or location. only contain the location.
A URI aims to identify a resource and A URL aims to find the location or address
differentiate it from other resources by of a resource on the web.
using the name of the resource or location
of the resource.
An example of a URI can be ISBN 0-486- An example of an URL is
35557-4. https://www.javatpoint.com.
It is commonly used in XML and tag It is mainly used to search the webpages
library files such as JSTL and XSTL to on the internet.
identify the resources and binaries.
The URI scheme can be protocol, The scheme of URL is usually a protocol
designation, specification, or anything. such as HTTP, HTTPS, FTP, etc.
Conclusions

• Internet Protocols and Standards:


– HTTP
– HTTPS
– FTP
– SMTP
– TCP/IP
– URI
– URL

You might also like