1transport layer
responsible for logical communications between applications running on different hosts; includes TCP and UDP
2transport layer responsibilities
tracking individual conversations, segmenting data and reassembling segments, adding header information, identifying the applications, conversation multiplexing
3tracking individual conversations
responsibility of transport layer to track each set of data flowing between a source and destination
4segmenting data and reassembling segments
responsibility to divide the application data into appropriately sized blocks; data may be called a segment or datagram
5add header information
adds information containing binary data organized into several fields to each block of data
6identifying the applications
transport layer must be able to separate and manage multiple communications with different transport requirement needs; uses port numbers to identify the target application
7conversation multiplexing
enables different communications to be interleaved on the same network
8transport layer protocols
specify how to transfer messages between hosts and are responsible for managing reliability requirements
9transmission control protocol (TCP)
considered a reliable, full-featured transport layer protocol, which ensures that all of the data arrives at the destination; includes additional processing for the hosts and divides data into segments
10TCP reliability and flow control operations
number and track data segments, acknowledge received data, retransmit any unacknowledged data, sequence data into correct order, send data at an efficient rate that's acceptable by the receiver
11user datagram protocol (UDP)
simpler transport layer protocol than TCP; provides the basic functions for delivering datagrams between the appropriate applications with very little overhead; connectionless, stateless, best effort
12TCP services
establishes a session, ensures reliable delivery, provides same-order delivery, supports flow control, is stateful so it records which information has been sent and which has been acknowledged
13TCP overhead
adds 20 bytes when encapsulating the application layer data
14TCP header fields
source and destination port, sequence number, acknowledgment number, header length, reserved, control bits, window size, checksum, urgent
15application protocols that use TCP
FTP, SMTP, SSH, HTTP
16UDP features
data is reconstructed in the order it was received, any segments that are lost aren't resent, no session establishment, sending isn't informed about resource availability
17UDP header fields
source and destination port, length, checksum
18types of applications best suited for UDP
live video and multimedia applications, simple request and reply applications, and applications that handle reliability themselves
19application protocols that use UDP
DHCP, DNS, SNMP, TFTP, VoIP, and video conferencing
20socket
the combination of an IP address and a port number; used to identify the server and the service being requested
21well-known ports
0-1,023; these ports are reserved for common or popular services and applications
22registered ports
1,024-49,151; these port numbers are assigned by IANA to a requesting entity to use with specific processes or applications; primarily individual applications that a user has chosen to install
23private dynamic ports
49,152-65,535; ephemeral ports; client's operating system usually assigns port numbers dynamically when a connection to a service is initiated
24netstat command
used to verify the active TCP connections which are open and running on a networked host; by default will attempt to resolve IP addresses to domain names and port numbers to well-known apps
25-n
option can be used to display IP addresses and port numbers in their numerical form
26open port
an active server assigned to a specific port; the transport layer accepts and processes segments addressed to that port
273-way handshake
1. SYN: initiating client requests a client-to-server communication session; 2. ACK and SYN: server acks the client-to-server communication session and requests a server-to-client communication session; 3. ACK: initiating client acks the server-to-client communication session
28FIN header
control flag that closes a connection
292-way handshake to terminate a conversation
1. FIN: when client has no more data to send in the stream, it sends a segment with the FIN flag set; 2. ACK: server sends an ACK to acknowledge receipt of the FIN; 3. FIN: server sends a FIN to client to terminate the server-to-client session; 4. ACK: client responds with an ACK
30functions of the 3-way handshake
establishes that the destination device is present on the network, verifies that the destination has an active service and is accepting requests, and informs the destination device that the source intends to establish a communication session on that port number
31flag
bits in the control bit field; a bit that's set to either on or off
32flags in the control bits field
URG, ACK, PSH, RST, SYN, FIN
33URG
urgent pointer field significant
34ACK
acknowledgment flag used in connection establishment and session termination
36RST
reset connection when an error or timeout occurs
37SYN
synchronize sequence numbers used in connection establishment
38FIN
no more data from the sender and used in session termination
39sequence numbers
assigned in the header of each packet to make sure all data is received and reassembled in the correct order; represent the first data byte of the TCP segment
40initial sequence number (ISN)
during session setup, an ISN is set; represents the starting value of the bytes that are transmitted to the receiving application; number is incremented by the number of bytes that have been transmitted
41expectational acknowledgement
acknowledgement used by TCP where the ACK number is sent back to the source to indicate the next byte that the receiver expects to receive
42selective ACK (SACK)
receiver can explicitly ask which segments were received including any discontinuous segments so sending host only needs to resend missing data
43flow control
the amount of data that the destination can receive and process reliably; can adjust the rate of data flow between the source and destination for a given session
44window size
determines the number of bytes that can be sent before expecting an ACK; the ACK # is the # of the next expected byte
45sliding windows
a destination sends ACKs as it processes bytes received and continual adjustment of the source send window; allows sender to continuously transmit the segments as long as the receiver is acknowledging the previous segments
46maximum segment size (MSS)
typically 1,460 bytes of data within each TCP segment; determined by subtracting the IP and TCP headers from the Ethernet max transmission unit which is 1500 by default