Chapter 30 - Introduction to TCP/IP Transport and Applications Flashcards

1
Q

What are some uses of UDP that TCP does not have?

A
  • Smaller segments and less processing cycles due to requiring less information in its header
  • UDP does not slow down data transfer
  • Some applications do not need error correction (real time applications like VOIP) so will use UDP. Applications such as FTP that are required for sending/receiving files will likely use TCP.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What transport functions are supported by both UDP and TCP? What transport layer functions are supported only by TCP?

A
  • Multiplexing using ports - UDP/TCP - Allows receiving hosts to choose the correct application for which data is destined based on port number.
  • Error correction (Reliability) - TCP - Adding sequence numbers to data headers and sending acknowledgements once data has been successfully received.
  • Flow control (Windowing) - TCP - Uses window sizes to protect buffer space and routing devices from being overloaded with traffic. Does this by including buffer space field in TCP acknowledgments that advises how much data the sender can safely send in the next segment.
  • Connection establishment and termination - TCP - Process used to intialise port numbers and Sequence and Acknowledgement fields.
  • Ordered data transfer and data segmentation - TCP - Sends a continuous stream of bytes from a higher layer process that is segmented for transmission and delivered to the same higher layer process at the receiving device in the same order.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is Multiplexing in TCP/UDP?

A
  • Allows the protocol to tell the receiving device specificially what application the data is destined for by adding a port number in the TCP/UDP header
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is a Socket?

A
  • An end point on one side of a Transport Layer connection between two applications
  • Consists of:
    - IP address
    - Transport protocol
    - Port number
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the different port ranges defined by IANA?

A
  • Well Known (System) Ports:
    - From 0 to 1023
    - Assigned by IANA
    - A strict review process is required to assign these to applications
  • User (Registered) Ports:
    - From 1024 to 49151
    - Assigned by IANA
    - Less strict review process to assign to applications when compared to Well Known
  • Ephemeral (Dynamic, Private) Ports:
    - From 49152 to 65535
    - Not assigned to specific applications. Intended to be used temporarily while an application is running
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

List well known port numbers

A
  • 20 - TCP - FTP data
  • 21 - TCP - FTP control
  • 22 - TCP - SSH
  • 23 - TCP - Telnet
  • 25 - TCP - SMTP
  • 53 - UDP/TCP - DNS
  • 67 - UDP - DHCP server
  • 68 - UDP - DHCP client
  • 69 - UDP - TFTP
  • 80 - TCP - HTTP
  • 110 - TCP - POP3
  • 123 - UDP - NTP
  • 161 - UDP - SNMP agent
  • 162 - UDP - SNMP manager
  • 443 - TCP - SSL
  • 514 - UDP - Syslog
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the TCP three-way handshake?

A
  • Used to establish TCP connections between applications
    - The initiator will send a TCP SYN flag (Used to synchronise sequence numbers) with a src and dst port in its TCP header
    - The receiver will respond with a TCP SYN and TCP ACK flag with the initiators src port as its dst port and the initiators dst
    port as its src port
    - The initiator will respond with its own TCP ACK
  • The connection is now established
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How does a TCP application terminate connections? (Four-way handshake)

A
  • Sends and ACK and FIN flag
  • Responder responds with an ACK flag to advise that it has received the request to close the connection
  • Responder sends and ACK FIN
  • Sender sends an ACK
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is a Connection-Oriented Protocol?

A
  • Also known as stateful
  • Requires an exchange of messages to establish a connection before data transfer can begin
  • Protocols using TCP will be Connection-Oriented
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is a Connectionless Protocol?

A
  • Also know as stateless
  • A protocol that does not require an exchange of messages and does not require an established connection before data transfer can begin
  • Protocols using UDP will be Connectionless
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is TCPs Error Recovery function otherwise known as?

A

Reliability

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How does TCPs Error Recovery work?

A
  • Numbers data bytes using the Sequence and Acknowledgement fields in the TCP header.
  • Uses the Sequence number in one direction combined with the Acknowledgement field in the opposite direction to determine if an error has occurred.
  • After a determined amount of data has been received (determined by the window size) by the receiver it will respond with an ACK that has a sequence number 1 higher than the most recently received segment. This is known as Forward Acknowledgement.
  • So if the sender receives an ACK with a lower sequence number than what it has already sent, it knows there has been an error and knows which segment to resend.

Example: Sender sends upto sequence 4. Receiver should acknowledge upto sequence 5 but only acknowledges upto sequence 2. Sender knows to resend sequence 3 upwards.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a Retransmission Timer?

A
  • How long a sender will wait after not receiving an ACK before responding with potentially lost data.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is Windowing?

A
  • Flow control used by TCP
  • Allows the sender to determine how much data is awaiting acknowledgement and processing by the receiver
  • The receiver will tell the sender how much data it can receive at that point in time
  • Uses a Sliding Window/Dynamic Window function to dynamically cause the sender to speed up or slow down tranmission
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Examples of applications that may prefer UDP over TCP.

A
  • Real time protocols like VoIP and video as if there were any errors, it would be too late to resend the missing segment without the data sounding/looking strange
  • DNS as if the resolution fails, the sender will just retry the operation again
  • NFS (Network File System) as it performs recovery at the application layer
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is a URI?

A
  • Uniform Resource Identifier
  • Also known as URL (Universal/Uniform Resource Locator)
  • The three main parts of a URI are
    - Scheme - The protocol being used to connect to the server (http)
    - Authority - The web server
    - Path - The web page located on the server
17
Q

True or False. A host has to send a DNS request for every connection to a URI

A

False. Hosts can cache DNS responses from prior DNS requests.

18
Q

What is Recursive DNS?

A
  • The process by which, if one DNS server does not know the destination IP that is resolved by a URI, it will refer the sending host to another DNS server that may know the answer.
  • This continues until the sending host has received the correct response.
19
Q

What fields in various headers identify the next header?

A
  • Layer 2 - Ethernet - Type field - Identifies the type of network header that follows (e.g. 0x0800 for IPv4)
  • Layer 3 - IPv4 - Protocol field - Identifies the type of transport header that follows (e.g. 6 for TCP, 17 for UDP)
20
Q

What is a port (Layer 4)?

A
  • A Transport Layer address
  • Identifies an Application Layer protocol
  • Allows for session Multiplexing
21
Q

What is Forward Acknowledgement?

A
  • The process that TCP uses to acknowledge the next sequence number that it expects to receive.
  • For example, if PC1 sends Seq 20, PC2 will respond with ACK 21, PC2 will then respond to that with Seq 21…