0% found this document useful (0 votes)
34 views42 pages

ANS 1 ProtocolsAndArchitectures 2223

The document discusses network protocols and architectures including layers, addressing, and the OSI and TCP/IP models. It describes the layered approach with different protocols and services at each layer for communication between networked devices.

Uploaded by

Fouzi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views42 pages

ANS 1 ProtocolsAndArchitectures 2223

The document discusses network protocols and architectures including layers, addressing, and the OSI and TCP/IP models. It describes the layered approach with different protocols and services at each layer for communication between networked devices.

Uploaded by

Fouzi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 42

1.

Protocols and
Architectures
Advanced Networks and Security
2021/22
1. Protocols and Architectures
• Learning objectives
• Remember how the layer mechanism used in
the data communication protocols works.
• Remember the use of the different layers of the
communication model for the interconnection
of devices with internal and external networks.

Advanced Networks and


Security - 2021/22 2
1. Protocols and Architectures
1. Protocols, interfaces and services
2. Network architectures

Advanced Networks and


Security - 2021/22 3
1. Protocols and Architectures
1. Protocols, interfaces and services
2. Network architectures

Advanced Networks and


Security - 2021/22 4
Example: μTorrent
• Generic services applicable to all applications that require
communication
-. [User and command interface, and code without
communications]
7. Application (program) specific communication
6. Character codification, encryption, etc.
5. Session (dialog [inside connection]) establishment and control
between final applications
4. (Reliable , with connection) end-to-end communication (and
segmentation, if necessary)
3. Network interconnection
2. (Reliable) host-host (including the router) communication inside
the same network, of frames (“packets”)
1. Signal/bit transmission in a physical medium
Advanced Networks and
Security - 2021/22 5
Protocols Architecture:
Parcel service between 2 offices
• Simple task: Send parcels between offices

• We will divide the task into 3 distinct processes:


• Sender side:
• Sender user: Take package, wrap it and address it.
• Mailman: Collects the parcels from the senders and takes
then to a mail dispatch room.
• Delivery: place parcels in a van and drive to the remote
office.
• Receiver side:
• Delivery: receives parcels and place them into a tray for the
mail man.
• Mailman: collects the parcels and delivers them to the
recipients.
• Receiver user: unwrap package & use.

• Any task can be changed without affecting others.


• Using train instead of van would not affect the mail man.
• The mailman doesn’t know, and doesn’t care, how the
parcels are transported between offices. All he does is
collect and deliver them inside office.
• One user can do more than 1 task. E.g. Sender may also take
the package to the mail dispatch room.

[http://www.steves-internet-guide.com/internet-protocol-suite-
explained/]

Advanced Networks and


Security - 2021/22 6
Protocols Architecture
• Implementation of the services
through modules
• Each module depends only on
the lower one  layers
• A protocol stack in each device
• The same layers are necessary in
both communicating systems
• Communication among remote
equal layers regulated by a
protocol:
• Semantics of the messages:
meaning
• Syntax of the messages: format
• Sequence of the messages

Advanced Networks and


Security - 2021/22 7
Layer: services, interfaces,
protocols
• N Layer...
• Provides services to the layer N + 1 (it does not depend on it)
• ... through a functional interface,
• and offering 1 Service Access Point of (SAP) for each existing layer N+1
• A layer N can be used by more than one different layer N+1
• It communicates, using a standard protocol, with layer N of remote system
• ... making use of the services offered by layer N - 1
• Layer N only depends on its layer N-1

Advanced Networks and


Security - 2021/22 8
Data flow and PDUs
• Protocol Data Units (PDU)
• In each layer the protocol adds control data (protocol information) to the data of the upper
layer, in the form of a header at the beginning [and sometimes also a trailer at the end].
• Control data provides part of the functionality in the layer, and it is the information that is
exchanged with the same layer of the remote system.
• Data from the upper layer, to be delivered to the remote upper layer, is included in the
PDU's "payload" field, after the header
• In reception, the layer analyzes the header, it carries out the associated tasks and if there are
no errors, it removes the header and delivers the rest, the payload, to the upper layer.
• In specific cases, e.g. during connection, PDUs with no upper layer data can be generated.

Advanced Networks and


Security - 2021/22 9
Addressing
• Two levels of addressing are required
• Every computer needs a unique address within the whole Internet
• Network Address (e.g. IP address)
• Identifies a network + one device within the network
• Each application requires a unique address within the computer (multitask)
• Service access point (SAP) (e.g. port)
• Identifies one application inside a computer
• In addition, there is a 3rd unique address for each network card
• Physical address (e.g. MAC address)
• Allows to communicate efficiently within the same network
• Each type of addressing is used in a different layer

Advanced Networks and


Security - 2021/22 10
Open Systems Interconnection (OSI)
Layers
• OSI Layers
• [User] (without communication and outside the TCP/IP layer model)
• [User and command interface, and code without communications]
• Application
• Application (program) specific communication
• Presentation
• Character codification, encryption, etc.
• Session
• Session (dialogue [inside connection]) establishment and control between final applications
• Transport
• (Reliable, with connection) end-to-end communication (and segmentation, if necessary)
• Network
• Network interconnection
• Data Link
• (Reliable) host-host (including the router) communication inside the same network, of frames
(“packets”)
• Physical
• Signal/bit transmission in a physical medium

Advanced Networks and


Security - 2021/22 11
TCP/IP Layers
• TCP/IP Layers
• [User] (without communication and outside the TCP/IP layer model)
• [User and command interface, and code without communications]
• Application
• Application (program) specific communication
• Character codification, encryption, etc.
• [Session (dialogue [inside connection]) establishment and control between final applications]
• Transport
• (Reliable, with connection) end-to-end communication (and segmentation, if necessary)
• Network / Internet*
• Network interconnection
• Network Access **
• (Reliable) host-host (including the router) communication inside the same network, of frames
(“packets”)
• Physical medium **
• Signal/bit transmission in a physical medium

• * Initially Internet layer


• ** Initially, they were a single layer (Link layer)

Advanced Networks and


Security - 2021/22 12
OSI vs. TCP/IP Layers
OSI TCP/IP
Application
Presentation Application
Session
Transport Transport
Network Network / Internet
Data link Network access
Physical Physical medium
Advanced Networks and
Security - 2021/22 13
OSI vs. TCP/IP Layers
• Different sources give different versions of the layers
• https://en.wikipedia.org/wiki/Internet_protocol_suite#Layer_names_and_number_of_layers
_in_the_literature

R. Martí - 2021/22 14
TCP/IP: services and layers
7. Application
• HTTP, SMTP, POP3, IMAPv4, DNS, FTP, etc.
4. Transport
• TCP (reliable, connection), UDP (unreliable, connectionless), RTP (7?), SCTP
3. Network
• For TCP/IP, here goes the Internet Protocol (IP)
• Can also be considered part of the network layer protocols
• Mandatory such as ICMP and IGMP, which are on top of IP
• routing protocols as OSPF, which are on top IP
• routing protocols as BGP and RIP, which for various reasons go on top TCP and UDP respectively
2. Data Link
• LLC, MAC ["Ethernet", 802.11 Wi-Fi, Token ring, ...], ATM, PPP, etc.
• ARP goes on top of the link layer, but can be considered within this layer.
1. Physical
• Physical medium, and coding techniques, T1, E1, ADLS, etc.
• Data link protocols sometimes include physical layer specifications (Ethernet, 802.11 Wi-Fi,
...)

Advanced Networks and


Security - 2021/22 15
TCP/IP: services and layers

Advanced Networks and


Security - 2021/22 16
TCP/IP: services and layers
• TCP/IP PDUs
• Application: Message with “operation request or response”
• Transport: Segment (TCP), User Datagram (UDP) (usually transports application data)
• Network / Internet: Datagram (usually transports a segment)
• Data Link / Network Access: Frame (usually transports a datagram)
• Physical medium / Physical : “bit”/signal (transports frames)

• Data in the network:

Data Link (...) Network (...) Transport (...) Application Data

Segment / User Datagram

Datagram
Frame

Advanced Networks and


Security - 2021/22 17
TCP/IP: services and layers
• PDU headers & Addressing:
• Application: No header. Usually includes the operation identifier and data
• Transport: Includes source + destination Service Access Point (SAP, e.g. port)
• Internet / Network: Includes source + destination network address (e.g. IP address)
• Network access / Data link: Includes source + destination physical address (e.g. MAC
address)
• Physical medium / Physical : [It clan include e.g. synchronization bits/signals]
• Data in the network:

D. Link. (Phys.@...) Netw. (Netw.@...) Trans. (SAP…) Operation Id, data ...

Segment / User Datagram

Datagram
Frame

Advanced Networks and


Security - 2021/22 18
Layers, Protocols, and PDUs
• Application: High level protocols: HTTP, SMTP, FTP, SNMP...
• message
• Transport: TCP (reliable), UDP (non reliable)
• segment (TCP), user datagram (UDP)
• Include ports (Service Access Point)
• Network: IP, ICMP...
• datagram
• Includes network/logic address (e.g. IP)
• Data link: Ethernet, Wi-Fi, ATM, ...
• frame
• Includes physical address (e.g. MAC)
• Physical: ADSL, Ethernet, Wi-Fi, ...
• “bits”/signals

Advanced Networks and


Security - 2021/22 19
1. Protocols and Architectures
1. Protocols, interfaces and services
2. Network architectures

Advanced Networks and


Security - 2021/22 20
TCP/IP Architecture
• We cannot directly connect elements from different
networks:
• They won’t understand each other!
• We need elements being in different networks at the same
time.
• These elements are the routers.

• Routers
• Routers are special computers/devices allowing the
interconnection of different physical networks.
Advanced Networks and
Security - 2021/22 21
TCP/IP Architecture
• Routers use networks, and do not care about computers.
• From the user’s point of view this is totally transparent:
• User does not need to know the inside of the networks.
• All networks are treated in the same way (LANs, WANs,
point-to-point links, ...).

Advanced Networks and


Security - 2021/22 22
TCP/IP: services and layers

Advanced Networks and


Security - 2021/22 23
Networks Interconnection
• Layer 1
• Repeater: extends the allowable length of a cable
• Repeats & regenerates bits to the other output
• Hub: connects multiple cable segments together and makes them act as a single network segment.
• Layer 2
• Bridge: connects segments of a network in a clever way
• Analyzes Physical @ (e.g. MAC) in frames to decide output
• Switch: takes the functions of the repeater and the bridge and combines them to create a clever
multi-port interconnect box
• Translating bridge: Connects segments of a network with different lower part of layer 2 technology
• Layer 3
• Router: connects dissimilar networks
• Analyzes Logical @ (e.g. IP) in datagrams to decide output
• Layer 3 switch: Layer 2+3 at the same time: blur the line between switching and routing. Connects
different networks with the same Layer 2 technology, but with ultra high-speed performance like
Layer 2 switches.
• Analyzes Physical @ + Logical @ to decide output
• Layer 1-7 (often 7)
• Gateway
• Data analysis / Format conversion of data from similar protocols

Advanced Networks and


Security - 2021/22 24
Interconnection devices summary
• Repeater (1), Bridge (2)
• 2 Network segments
• Hub (1), Switch (2 ‘lower’)
• Computers / Network segments
• Translating bridge (2 ‘upper’)
• 2 Network segments (of different layer 2 technology)
• Router (3)
• Different networks
• Layer 3 switch (2+3)
• Different networks (of same layer 2 technology) + Computers (inside these
netw.)
• Gateway (1 to 7, often 7)
• All of the above
• + [Application] data analysis / Format conversion of [application] data from
similar protocols

Advanced Networks and


Security - 2021/22 25
Interconnection devices summary

Advanced Networks and


Security - 2021/22 26
Networks Interconnection

Routers
Switches Have Three
Source and Layers
Have Two
Destination ---
Layers
Hosts Have Each Router
---
5 Layers Port
Each Switch
App Port Has Two
Trans Has One Layers
Int Layer
DL
Phy
Source Switch 1 Switch 2 Router 1 Switch 3 Router 2 Destination
Host Host

Advanced Networks and


Security - 2021/22 27
Networks Interconnection

Hypertext Transfer Protocol


App

Transmission Control Protocol


Trans

Internet Protocol
Int

DL

Phy

Source Switch 1 Switch 2 Router 1 Switch 3 Router 2 Destination


Host Host

Advanced Networks and


Security - 2021/22 28
1. Protocols and Architectures
• What have we learned / remembered?
• How the layer mechanism used in the data
communication protocols works.
• The use of the different layers of the
communication model for the interconnection
of devices with internal and external networks.

Advanced Networks and


Security - 2021/22 29
References
References
• Data and Computer Communications, 10th Edition. W.
Stallings. Pearson Prentice Hall, 2014
• Comunicacions informàtiques i de dades,. 8a Edició. W.
Stallings. Pearson Prentice Hall, 2007. Fundació privada
Torrens-Ibern, 2010
• http://www.torrens-ibern.cat/?page_id=163
• Aspectos avanzados de seguridad en redes. Jordi Herrera
Joancomartí (coord.), Joaquín García Alfaro, Xavier Perramón
Tornil. Segunda edición, febrero 2007. Fundació per a la
Universitat Oberta de Catalunya
• http://ocw.uoc.edu/informatica-tecnologia-y-multimedia/aspectos-
avanzados-de-seguridad-en-redes/materiales/

Advanced Networks and


Security - 2021/22 31
References
• Protocols and Architectures
• Business Data Communications, 7e,
William Stallings and Tom Case,
Prentice Hall, September 2012 ©
• Chapter 1 “Introduction”
• Chapter 7 “The Internet”

Advanced Networks and


Security - 2021/22 32
Additional Slides
1. Protocols and Architectures
1. Protocols, interfaces and services
2. Network architectures

Advanced Networks and


Security - 2021/22 34
TCP/IP: services and layers
• Layer 1: Physical medium
• Physical interface between the computer and the
transmission medium
• Hardware (card) + network driver
• Medium Access and configuration services
(signals levels, speed)
• Bit level transmission and reception
• Through electrical/optical signals
• Protocol dependant on the physical medium
Advanced Networks and
Security - 2021/22 35
TCP/IP: services and layers
• Layer 2: Network access
• Exchange of data among devices that share the same
physical medium, and among computers of the same
network
• It can provide reliability
• Physical addressing (MAC)
• Network services, like priorities, Medium access control
• Transmission of data packages
• PDU= frame
• Protocol dependant on the type of network

Advanced Networks and


Security - 2021/22 36
TCP/IP: services and layers
• Layer 3: Internet
• Network interconnection layer
• Independent from the type of network
• Certain dependence to the characteristics of the network
• Fragments data if data are bigger than the maximum size allowed by the
network
• (Non reliable) routing services through multiple networks
• Network addresses (f.e. IP) are necessary to identify networks
and hosts
• Implemented in hosts and in routers
• Protocols: IP, ICMP...
• IP Addressing
• PDU = datagram

Advanced Networks and


Security - 2021/22 37
TCP/IP: services and layers
• Layer 4: Transport
• Responsible of the end-to-end communication between processes
• Control of the connections among extremes
• Independent of the physical medium, type of network or application
data to transport
• Delivery of data to the applications
• Reliable (TCP, Transmission Protocol Control): without errors, duplicates
nor losses, and keeping the order.
• Non reliable (UDP, User Datagram Protocol).
• Fragmentation of user data
• In small packages for best management of the transmission
• Protocols: TCP and UDP,...
• It includes addressing with SAPs (ports) for the application level
• PDU = segment (TCP), user datagram (UDP)

Advanced Networks and


Security - 2021/22 38
TCP/IP: services and layers
• Layer 5 (7): Application
• Specific support for each user application
• Coding of the information
• Depending on the application
• High level protocols: HTTP, SMTP, FTP, SNMP...
• Addressing with SAPs (ports) included at the transport
layer
• PDU = message
• Normally with operations and answers; with format,
arguments and results, specific, for each application.

Advanced Networks and


Security - 2021/22 39
Session
• [https://en.wikipedia.org/wiki/Session_(computer_science)]
• In computer science, in particular networking, a session is a temporary and
interactive information interchange between two or more communicating devices,
or between a computer and user (see login session).
• A session is established at a certain point in time, and then torn down at some
later point.
• An established communication session may involve more than one message in
each direction.
• A session is typically stateful, meaning that at least one of the communicating
parts needs to save information about the session history in order to be able to
communicate, as opposed to stateless communication, where the communication
consists of independent requests with responses.
• An established session is the basic requirement to perform a connection-oriented
communication.
• A session also is the basic step to transmit in connectionless communication
modes.
• However any unidirectional transmission does not define a session.

Advanced Networks and


Security - 2021/22 40
Communication Protocols
7 Application
• HTTP, SMTP, POP3, IMAPv4, SNMP, FTP, Telnet, SSH i SCP, NFS, RTSP, Feed, Webcal,
XMPP, Whois
6 Presentation
• XDR, ASN.1, SMB, AFP
5 Session
• TLS, SSH, ISO 8327 / CCITT X.225, RPC, NetBIOS, ASP
4 Transport
• TCP, UDP, RTP (7?), SCTP, SPX, ATP
3 Network
• IP, ICMP, IGMP, BGP, OSPF, RIP, IGRP, EIGRP, ARP, RARP, X.25, IPsec
2 Data link
• Ethernet, Token ring, HDLC, Frame relay, ISDN, ATM, 802.11 WiFi, FDDI, PPP
1 Physical
• cable, radio, optical fiber [, ADSL][, Ethernet, 802.11]

Advanced Networks and


Security - 2021/22 41
Networks Interconnection
• "Making The Connection"
A poem by Joseph Bardwell

Sometimes it amazes me
that routers work at Layer 3
when switches very will could do
the job at simply Layer 2

But switches work at Layer 3


Oh, how confusing this can be
When bridges work at Layer 2
and routers can be bridges too!

And when you hope there'd be no more


you find a switch at Layer 4
So Layer 4, and 2, and 3
imply OSI conformity

But these are simply building blocks


in what we'll call an "Interconnect Box"

Advanced Networks and


Security - 2021/22 42

You might also like