CSC 465 Data Communication and Computer Networks
CSC 465 Data Communication and Computer Networks
CSC 465
Data Communication and Computer Networks
• Why Layering?
Data communications requires complex procedures
o Sender identifies data path / receiver
o System negotiate responsiveness
o Translation of file formats
A high level of cooperation is needed for all tasks to occur
Provide framework to implement multiple specific protocols
per layer
CSC 465 3
Layered Tasks
• Three different activities at the sender and three at the receiver site
• Must be done in the order of the layers
• Each layer at the sending site uses the services of the layer right below it
CSC 465 4
The OSI Model
CSC 465 5
The OSI Model (Cont’)
CSC 465 6
The OSI Model (Cont’)
CSC 465 7
The OSI Model (Cont’)
CSC 465 8
Layers in the OSI Model: Application Layer
• This layer provides user interfaces and support for services (e.g., electronic
mail, remote file access and transfer, shared database management etc.)
• Specific services provided by the application layer include the following
– Network virtual terminal
– File transfer, access, and management
– Mail services
– Directory services
CSC 465 9
Layers in the OSI Model: Presentation Layer
• This layer is concerned with syntax and semantics of data being transmitted
• As part of translation, encodes messages in a format that is suitable for
electronic transmission
• Data encryption, and compression are also done at this layer
CSC 465 10
Layers in the OSI Model: Session Layer
Transport layer is responsible for the delivery of a message from one process to another
• This layer ensures the whole message arrives intact and in order, overseeing
both error control and flow control at the source-to-destination level
• Service-point addressing.
• Segmentation and reassembly.
• Connection control.
CSC 465 12
Layers in the OSI Model: Network Layer
Network layer is responsible for the delivery of individual packets from source to destination
• This layer ensures that each packet gets from its origin to its final destination
• If two systems are attached to different networks (links) with connecting devices
between links, network layer is used to accomplish source-to-destination delivery
• Logical addressing. Network layer adds logical addresses of the sender and receiver
• Routing. Routers route the packets to their final destination
CSC 465 13
Layers in the OSI Model: Data Link Layer
Data link layer is responsible for moving frames from one hop to the next
•This layer transforms physical layer, a raw transmission facility, to a reliable link and it
makes physical layer appear error-free to the upper layer (network layer)
•Framing. Divides the stream of bits into frames
•Physical addressing. Adds a header to define the sender and/or receiver of the frame
•Flow control. This mechanism to avoid overwhelming the receiver (receiver slower than
sender);
•Error control. Detect and retransmit damaged or lost frames; Recognize duplicate frames
CSC 465 14
Layers in the OSI Model: Physical Layer
Physical layer is responsible for the movement of individual bits from one hop to the next
CSC 465 16
Transmission Control Protocol/
Internet Protocol (TCP/IP)
• TCP/IP is a network standard that defines how messages
are routed from one end of a network to another
• Four layers TCP/IP compared to OSI:
4. Application => Session, Presentation & Application
3. Transport
2. Internet => Network
1. Host-to-network => Physical & Data link
• However, Five layers are consider for TCP/IP protocol
suite
CSC 465 17
OSI model & Internet Protocol Stack
Layer OSI Model PDU TCP/IP Model Layer
7 Application
6 Presentation Data Application 5
5 Session
4 Transport Segment Transport 4
3 Network Packet Internet 3
2 Link Frame Link 2
1 Physical Bits Physical 1
CSC 465 19
Internet Protocol Stack/
OSI Reference Model
•Application: Supporting network applications
•FTP, SMTP, HTTP
•Transport: Process-process data transfer
• TCP, UDP, SCTP
•Network: Routing of datagrams from source to destination
•IP, routing protocols
•Link: Data transfer between neighboring network elements
•Ethernet, 802.111 (WiFi), PPP
•Physical: Bits “on the wire”
CSC 465 21
TCP/IP
Encapsulation and Decapsulation (Cont’)
Example: (See the figure from previous-slide)
• When ‘Computer A’ sends a message to ‘Computer B’ using a chat program, the
message data is passed from Application layer (chat program) to Transport
layer. The Transport layer wraps (encapsulates) the entire data and adds the
TCP header/footer (it can be UDP data/footer depending on application), after
that send to lower layer, Network layer. The Network layer wraps the received
data and adds the IP header/footer, sends to Link layer. The same process
happens in Link layer and then the encapsulated data is sent through physical
network link to the Internet
• When the encapsulated data arrived at the destination (‘Computer B’), the
unwrapping (decapsulation) process would happen. The Link layer removes its
frame header and footer from the encapsulated data, moves it to upper layer,
Network layer. The Network layer would also remove the IP header/footer and
pass the remains to Transport layer. The same process happens in Transport
layer and the original data is passed to Application layer. End user of ‘Computer
B’ would then see the message end user of ‘Computer A’ typed at last.
CSC 465 22
Addressing
• Four levels of addresses are used in an internet employing the
TCP/IP protocols: physical, logical, port, and specific
• Each address is related to a one layer in the TCP/IP architecture
CSC 465 23
Physical Addresses
• A node with physical address 10 sends a frame to a node with physical address
87. The two nodes are connected by a link (bus topology LAN).
• The computer with physical address 10 is the sender, and the computer with
physical address 87 is the receiver.
• In most data link protocols, the destination address (87) comes before the
source address (10).
CSC 465 27