L5 Network and Transport Layers Flashcards
What does the Transport Layer do?
Provides an error-free data delivery service to the Application Layer
- Repackaging upper layer data into manageable sized chunks (segments) for transmission on the network
- Reassembling segments into larger data units to give to the Application Layer entity
- Makes sure that data is delivered to the Application Layer in the order it was sent
- Detects and solves loss data
- Detects and solves duplicate data
- Provides metering (i.e. flow control) of data to the network laye
Explain how data encapsulation works layer by layer.
The App header and App data are added on at the Application layer. The TCP header and App data-2 are added on at the Transport layer. The IP header is added on at the Network layer. The Layer-2 header and Layer-2 trailer are added on at the Data Link layer.
What is TCP/IP?
A group of protocols.
TCP and IP are not the same.
TCP is a protocol used in the Transport Layer in the internet model.
IP is the protocol used at the Network layer in the internet model.
Why is TCP/IP the dominant protocol used in the Transport and Network layer today?
- Linked to the introduction of the Internet (via ARPANET)
- Open non-proprietary protocols
- Scalable addressing scheme allows very large manageable networks
- Critical mass and momentum
What are the 10 mandatory and 1 optional field that exists in the TCP header?
- Source port
- Destination port
- Sequence number
- ACK number
- Header length
- RFU
- Flags
- Window Size
- Checksum
- URG
- Options
IT has 20 bytes in total.
What does the Sequence Number of the TCP header do?
Numbers each segment transmitted so that the receiver can reassemble them in the right order.
What does the ACK number of the TCP header do?
Acknowledges segments – sliding window style
What does the Window size of the TCP header do?
Dynamically adjusts the window size for Flow control.
How does TCP segmenation work?
TCP breaks upper layer packets into 2 smaller parts and sends them as two separate segments. It splits the application layer head and user data and then adds a TCP header to each. These segments are then reassembled into a single PDU before being sent to the Application layer.
Explain how the maximum segment size in (MSS) works with regards to TCP.
The maximum segment size is the largest chunk of user data sent in the TCP segment. The total length of a TCP segment is the maximum segment size + the TCP header.
The Ethernet MTU = IP header + TCP header + User data. The Ethernet header and trailer follow this.
What is a session?
An active exchange of information (dialog, conversation) between two Application Layer peers which have established a connection.
It has a 2-way communication. The connection is maintained by the TCP.
What is connection oriented messaging?
Used by Applications that want guaranteed data delivery ex. FTP, SMTP, HTTP
What are the steps in a 3-way handshake to establish a TCP connection session?
- Synchronization characters are sent from the client to the server
- A synchronization acknowledgement is sent back to the client from the server
- An acknowledgement is then sent from the client to the server
What are the four steps in a 4-way handshake to terminate a TCP connection session?
- FIN sequence is sent from client to server to say that no more data needs to be sent.
- An acknowledgement is sent from the server back to the client
- A FIN sequence is sent from the server to client
- An acknowledgement is then sent from the server to the client
What is connectionless messaging?
A session hat has not been set up between communicating peers. Used by applications who don;t need guaranteed data delivery. UDP (user datagram protocol) is used to transfer the data.
What is UDP?
User Datagram Protocol. Its used when TCP adds to much overhead (UDP takes up only 8 bytes while TCP takes 20 bytes).
UDP offers:
- No segmentation (or reassembly)
- No error checking (usually checksum not used)
- No (re)sequencing
- No retransmission of lost data
- Low overhead
- Low latency
ex of uses: volp, real-time video,
What is QOS (Quality of service)?
QoS defines different classes (of service) into which a connection is placed, connections are given different priorities.
Best used on virtual or private networks.
Gives high priority to time sensitive data ex. voice data and real-time video
Which protocols support QOS (Quality of service)?
Resource Reservation Protocol (RSVP)
Real-time Streaming Protocol (RTSP)
Real-time Transport Protocol (RTP)
What does the network layer do?
Provides a transparent network-wide path between two transport layer entities
What protocol does the network layer use?
Internet Protocol (IP).
What does Internet protocol (IP) do?
Sets the proper source and destination network addresses in the packet before forwarding to the Data Link layer. It uses the destination address to determine the next hop, i.e. which interface/port on the device to send the packet out (the routing decision)
TWO versions of IP in current use: IPv4 and IPv6
An IP address is divided into two parts: a fixed part that is the same for every host on the same subnetwork and a variable part that is unique to each host on the network
Name the 13 mandatory and 1 optional field in the IPv4 header?
- Ver
- Hdr len
- DSCP/ECN
- Total length
- Ident
- Flags
- Frag offset
- TTL
- Protocol
- Checksum
- Src Addr
- Dest Addr
- User data
Name the 8 mandatory fields in the IPv6 header
- Version
- Traffic class
- Flow label
- Payload length
- Next header
- Hop limit
- Source address
- Destination address
- ? User data
contains 40 bytes
What kind of addresses exist in networking?
- Domain name - Identifies a host (e.g. server) using a naming convention that is easy for humans to remember and manipulate ex. carleton.ca
- Network layer address - The address that identifies to the network layer the interface used to connect to the communications network ex. IP address
- Data link layer address - The address that identifies the physical port of the device connected to the network segment ex. ethernet MAC