Vous êtes sur la page 1sur 37

Application Layer (Layer 7)

• An application that communicates with other


computers is implementing OSI application layer
concepts. The application layer refers to
communications services to applications. For
example, a word processor that lacks
communications capabilities would not implement
code for communications, and word processor
programmers would not be concerned about OSI
Layer 7. However, if an option for transferring a file
were added, then the word processor would need
to implement OSI Layer 7 (or the equivalent layer
in another protocol specification).
– Telnet, HTTP, FTP, WWW browsers, NFS,SMTP
gateways (Eudora, CC:mail), SNMP, X.400 mail,
FTAM
Types of Applications
• Direct Network Applications
– Most applications that work in a networked
environment are classified as client-server
applications. These applications, such as
FTP, web browsers, and e-mail, all have two
components, which allow them to function -
the client side, and the server side. The client
side is located on the local computer and is
the requestor of the services. The server side
is located on a remote computer and provides
services in response to the client's requests.
Direct Network Applications
(cont.)
• A client-server application works by constantly repeating the following
looped routine: client-request, server-response; client-request, server-
response; etc. For example, a web browser accesses a web page by
requesting a uniform resource locator (URL), or web address, on a
remote web server. After it locates the URL, the web server that is
identified by that URL responds to the request. Then, based on the
information received from the web server, the client can request more
information from the same web server, or can access another web
page from a different web server.
Types of Applications

• Indirect Network Applications


– Within a LAN environment, indirect-application
network support is a client-server function. If a
client wants to save a file from a word processor
to a network server, the redirector enables the
word processing application to become a network
client.
– Redirector is a protocol that works with computer
operating systems and network clients instead of
specific application programs
Indirect Network Applications
(cont.)
• Examples of redirectors
– Apple File Protocol
– NetBIOS Extended User Interface (NetBEUI)
– Novell IPX/SPX Protocols
– Network File System (NFS) of the TCP/IP Protocol
Suite
Indirect Network Applications
(cont.)
• The requester software is part of the network client software that is
installed on the client computer of a network. The requester
(redirector) part of the software works with client computer’s
operating system to determine if the operation that is to be performed
needs to use network resources or local computer resources.
Indirect Network Applications
(cont.)
• A redirector (requester) will allow a local company
to use network storage devices as if they were
locally attached. This is done through the use of
drive mappings.
Presentation Layer (Layer 6)
• The presentation layer is responsible for presenting data in a form
that the receiving device can understand. To better understand the
concept, use the analogy of two people speaking different
languages. The only way for them to understand each other is to
have another person translate. The presentation layer serves as the
translator for devices that need to communicate over a network
• Insures data is readable by receving system
• Deals with format of the data and data structures
• Negotiates data transfer syntax for application layer
• Examples
– JPEG, ASCII, EBCDIC,TIFF, GIF, PICT, encryption, MPEG, MIDI, etc.
Presentation Layer

• Three Main Functions


– Data Formatting (Presentation)
– Data Encryption
– Data Compression
Data Formatting
• ASCII - Interchange
• EBCDIC - Extended Binary Coded
Decimal Interchange Code
 PICT - a picture format used to
transfer QuickDraw graphics between
programs on the MAC operating
system
 TIFF (Tagged Image File Format) - a
format for high-resolution, bit-mapped
images
 JPEG (Joint Photographic Experts
Group) - graphic format used most
often to compress still images of
complex pictures and photographs
 MIDI (Musical Instrument Digital
Interface) - for digitized music
 MPEG (Motion Picture Experts Group)
- standard for the compression and
coding of motion video for CDs and
digital storage
 QuickTime - a standard that handles
audio and video for programs on both
MAC and PC operating system
Session Layer (Layer 5)
• The session layer defines how to start, control, and end
conversations (called sessions). This includes the control and
management of multiple bidirectional messages so that the
application can be notified if only some of a series of messages
are completed. This allows the presentation layer to have a
seamless view of an incoming stream of data. The presentation
layer can be presented with data if all flows occur in some
cases. For example, an automated teller machine transaction
in which you withdraw cash from your checking account should
not debit your account, and then fail, before handing you the
cash, recording the transaction even though you did not
receive money. The session layer creates ways to imply which
flows are part of the same session and which flows must
complete before any are considered complete.
– RPC, SQL, NFS,
– NetBIOS names,
– AppleTalk ASP, DECnet
– SCP
Session Layer (cont.)
• Accounting, conversation control
– who can talk when, and session parameter negotiation.
• Dialogue control and seperation
– enable applications to communicate between the source and
destination
Session Layer (cont.)
Dialogue Control
• Two-way alternate communication
– Communication partners take turns while sending messages to
avoid interrupting each other.
– For example; Internet Relay Chat (IRC)
• Two-way simultaneous communication
– Communication partners send each other whatever they want
without waiting turns.
– Synchronization Problem
Session Layer (cont.)
Dialogue Seperation
• Dialogue separation is the orderly initiation,
termination, and managing of communication.
The main graphic illustrates a minor
synchronization. At the "Time Axis,
t = checkpoint", the host A session layer
sends a synchronization message to host B, at
which time both hosts perform the following
routine:
1. back up the particular files
2. save the network settings
3. save the clock settings

4. make note of the end point in the
conversation

• A major synchronization would involve more back-and-


forth steps and conversation than is shown in this
diagram.
Session Layer (cont.)
Dialogue Seperation

• Checkpointing is similar to
the way a word processor
on a stand-alone computer
pauses for a second when it
performs an AutoSave of
the current document.
However, these checkpoints
are used, instead, to
separate parts of a session
previously referred to as
dialogues.
Session Layer Protocols
• Network File System (NFS)
• Structured Query Language (SQL)
• Remote Procedure Call (RPC)
• X-Window System
• AppleTalk Session Protocol (ASP)
• Digital Network Architecture Session Control
Protocol (DNA SCP)
The Transport Layer
 Layer4 of the OSI reference model. This layer is
responsible for reliable network communication
between end nodes. The transport layer provides
mechanisms for the establishment, maintenance,
and termination of virtual circuits, transport fault
detection and recovery, and information flow
control.
TCP/IP Protocol Suite has two
Transport Layer Protocols (TCP & UDP)
• TCP (Transmission Control Protocol) supplies a virtual circuit
between end-user applications. These are its characteristics:
– connection-oriented
– reliable
– divides outgoing messages into segments
– reassembles messages at the destination station
– re-sends anything not received
– reassembles messages from incoming segments.
– flow control
• UDP (User Datagram Protocol) transports data unreliably between
hosts. Following are the characteristics of UDP:
– connectionless
– unreliable
– transmit messages (called user datagrams)
– provides no software checking for message delivery (unreliable)
– does not reassemble incoming messages
– uses no acknowledgments
– provides no flow control
TCP/IP Protocol Graph
TCP Segment Format

source port -- number of the calling


port
destination port -- number of the
called port
sequence number -- number used
to ensure correct sequencing of
the arriving data
acknowledgment number - next
expected TCP octet
HLEN -- number of 32-bit words in
the header
reserved -- set to zero
code bits -- control functions (such
as setup and termination of a
session)
TCP Segment Format (cont.)

window– specifies the size of


the sender’s receive
window (that is, the buffer
space available for
incoming data)
checksum -- calculated
checksum of the header
and data fields
urgent pointer -- indicates
the end of the urgent data
option-one option --
maximum TCP segment
size
data -- upper-layer protocol
data
UDP Datagram Format
• User Datagram Protocol (UDP) is the connectionless transport
protocol in the TCP/IP protocol stack. UDP is a simple protocol that
exchanges datagrams, without acknowledgments or guaranteed
delivery. Error processing and retransmission must be handled by
other protocols.
• UDP uses no windowing or acknowledgments, therefore application
layer protocols provide reliability. UDP is designed for applications
that do not need to put sequences of segments together.
• Protocols that use UDP include:
– TFTP (Trivial File Transfer Protocol)
– SNMP (Simple Network Management Protocol)
– DHCP (Dynamic Host Control Protocol)
– DNS (Domain Name System)
Port Numbers
• Both TCP and UDP use port (or socket) numbers to
pass information to the upper layers. Port numbers are
used to keep track of different conversations that
cross the network at the same time.
Port Numbers (cont.)

• Application software developers have agreed to use


the well-known port numbers that are defined in
RFC1700.
– Windows 2000  c:\winnt\system32\drivers\etc
– Linux/Unix  /etc/services

• Reserved Port Numbers


– Numbers 0 - 255 for public applications
– Numbers from 256-1023 assigned to companies
for marketable applications
– Numbers above 1024 -65536 are unregulated
TCP Mechanisms
• Data transfer
• Multiplexing
• Error recovery (reliability)
• Flow control using windowing
• Connection establishment and termination

• Exam Certification Guide Page 217


Ordered Data Transfer
• TCP accomplishes data transfer by establishing a
connection between a socket on each of the
endpoint computers.
• Applications use TCP services by opening a
socket; TCP manages the delivery of the data to
the other socket.
• A socket source/destination pair uniquely
identifies a relationship between two applications
in a network. TCP manages the ordered transfer
of data between these two sockets, using IP
services to deliver the data.
Multiplexing
Error Recovery Reliability
• TCP provides sequencing of segments with a forward reference
acknowledgment. Each datagram is numbered before transmission. At the
receiving station, TCP reassembles the segments into a complete
message. If a sequence number is missing in the series, that segment is
re-transmitted. Segments that are not acknowledged within a given time
period result in re-transmission
• Positive acknowledgment and retransmission, or PAR, is a common
technique many protocols use to provide reliability. With PAR, the source
sends a packet, starts a timer, and waits for an acknowledgment before
sending the next packet. If the timer expires before the source receives an
acknowledgment, the source retransmits the packet and starts the timer
over again.
Flow control using windowing
• Window size determines the amount of data
that you can transmit at one time before
receiving an acknowledgment from the
destination. The larger the window size
number (bytes), the greater the amount of
data that the host can transmit. After a host
transmits the window-sized number of bytes,
the host must receive an acknowledgment
that the data has been received before it can
send any more messages. For example, with
a window size of 1, each individual (1)
segment must be acknowledged before you
can send the next segment.
• TCP uses expectational acknowledgments,
meaning that the acknowledgment number
refers to the octet that is next expected. The
"sliding" part, of sliding window, refers to the
fact that the window size is negotiated
dynamically during the TCP session. This
results in inefficient use of bandwidth by the
hosts.
Connection Establishment and
Termination

Three-Way Handshake / Connection Establishment


SYN & ACK Flags
Two single-bit portions of the flags field of the TCP header are
used to signal the three-step process for connection
establishment. Called the SYN and ACK flags, these bits have a
particularly interesting meaning. SYN means, “Synchronize the
sequence numbers,” which is one necessary component in
initialization for TCP. The ACK field means “the acknowledgment
field is valid in this header.”
Connection Establishment and
Termination
• This four-way termination sequence is straightforward and uses
an additional flag, called the FIN bit. (FIN is short for “finished,”
as you might guess.) One interesting note: Before the device
receiving the first FIN segment sends the third flow in the
sequence, TCP notifies the application that the connection is
coming down. TCP waits on an acknowledgment from the
application before sending the segment. That’s why the second
flow is required: To acknowledge the first so that the side
taking down the connection doesn’t start resending the first
TCP segment.
The Domain Name System (DNS)
• Internet is built on a hierarchical
addressing scheme. All protocols uses 32-
bit IP addresses for network
communication.
– They are difficult to remember
– Do not provide a functional logical grouping
• Domain Name System
– Host name  IP Address Mapping
The Domain Name System
(cont.)
• The Domain Name System (DNS) is a distributed
database used by TCP/IP applications to map between
hostnames and IP addresses
• Each site maintains its own database in its Domain
Name Server or Internet Service Providers provides this
service to their customers.
• DNS Servers also resolves hostnames to IP addresses
upon a client request (resolver function)
Fully Qualified Domain Name (FQDN)
• When using the Domain Name System, it is common to work with only
a part of the domain hierarchy, for example, the ral.ibm.com domain.
The Domain Name System provides a simple method of minimizing the
typing necessary in this circumstance. If a domain name ends in a dot
(for example,www.btegitim.com.), it is assumed to be complete. This is
termed a fully qualified domain name (FQDN) or an absolute
domain name. However, if it does not end in a dot (for example,
www.btegitim), it is incomplete and the DNS resolver may complete
this, for example, by appending a suffix such as .com or .com.tr to the
domain name. The rules for doing this are implementation-dependent
and locally configurable.
Hierarchical Name Space
• TLDs (Top Level Domains)
Root Servers
• If the name server doesn't contain the information requested, it must
contact another name server. Not every server, however, knows how
to contact every other server. Instead, every name server must know
how to contact the root name servers. The root servers then know the
name and location (i.e. IP address) of each authoritative name servers
for all the second-level domains. There are six root servers in the
world and every primary name server has to know the address of one
of root server.
Resource Record Types / Query Types

Vous aimerez peut-être aussi