1 / 22

CS3505 The Internet and Info Hiway transport layer protocols : TCP/UDP

CS3505 The Internet and Info Hiway transport layer protocols : TCP/UDP. transport layer : purpose. provides and end-to-end (host to host) data transfer service to its “customers” : applications (e-mail, FTP, Telnet, HTTP, telephony)

graham
Download Presentation

CS3505 The Internet and Info Hiway transport layer protocols : TCP/UDP

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CS3505 The Internet and Info Hiwaytransport layer protocols : TCP/UDP

  2. transport layer : purpose • provides and end-to-end (host to host) data transfer service to its “customers” : applications (e-mail, FTP, Telnet, HTTP, telephony) • interface between network/internet (e.g., IP) and the applications --TCP and UDP are the major TPs in use today, and these operate over IP

  3. TCP/IP internet ... TCP/IP IP IP WAN TCP/IP IP WAN IP TCP/IP

  4. protocol hierarchy applications : email, FTP, Telnet, WWW TP: TCP or UDP IP/NW protocol network/internet

  5. major Internet protocols • “TCP/IP protocol suite” (1) IP internet protocol (2) UDP - user datagram protocol (3) TCP - transmission control protocol -- 1 : network/internet layer -- 2,3 : transport layer

  6. other major Internet protocols ARP, RARP, BOOTP - reconciling IP, LAN addresses DNS - domain name system SNMP - simple network mgt protocol FTP - file transfer protocol Telnet, Rlogin - remote terminal access

  7. telnet, FTP, etc. apps TFTP, other apps. TCP UDP ICMP IP IGMP RARP ARP LAN/WAN media

  8. UDP : user datagram protocol • basic function of UDP -- to provide a simple, fast, easy datagram service. (not connection-oriented, delivery not guaranteed) -interfaces between IP and the application

  9. UDP : user datagram protocol -provides “bare bones” transport service -works as well as IP (best effort, no guarantees) -adds source and destination port number to packet and passes on to IP (multiplexing) -does NOT provide sequencing acknowledgments flow/congestion control

  10. UDP packet format 0 15 31 destination port source port UDP checksum UDP length DATA

  11. protocol and port numbers • Q1: how does IP know who to hand a datagram off to (UDP, TCP, or other) ? • Q2: how does UDP know who to hand the data to? • 0-1023 are “well-known port numbers”; others can be assigned on demand • the term “port” was a poor choice of terms

  12. reliable, stream transport : TCP • basic function of TCP -- to provide reliable, connection-oriented data transfer service, between the local application (email, web, FTP, Telnet, etc) and the distant application. internet

  13. reliable, stream transport : TCP 5 features characterize TCP protocol service : 1. stream orientation 2. virtual circuit connection 3. buffered transfer 4. unstructured stream 5. full duplex connection

  14. TCP connection : pair of sockets internet TCP TCP 2075 21 240.32.66.9 131.120.1.60 (2075, 131.120.1.60) ---------------(21, 240.32.66.9)

  15. TCP packet format destination port source port sequence number (sending) sequence number (acknowledgment) HLEN RES 6 flags window size TCP checksum urgent pointer options (if any) DATA

  16. TCP fields, comments • Header: 20 bytes minimum • data : 216 - 20(IP header) - 20(TCP header) = 65495 bytes maximum • port - TCP customer; i.e., FTP, email, etc. • TCP customer may do further multiplexing (why?) • socket : TCP endpoint; a pair (host, port) of integers • TCP connection : a pair (S1,S2) of sockets

  17. TCP fields - flags • URG - urgent pointer valid... if set, points to last byte of urgent data (implementations vary) • ACK - acknowledgment valid • PSH - push; pass to app quickly as possible • RST - reset the connection(close connection immediately, error) • SYN - synchronize sequence numbers to initialize a connection • FIN - finished sending data

  18. more on TCP • opening connections - both sides must agree on parameters before data passed • connection establishment - 3 way handshake (SYN,SYN,ACK) • segments - one TCP packet • window size - variable, established when connection made • flow control • out of band data

  19. TCP connection establishment • 3 way handshake (3 messages needed) 1. “client” sends a connect request (SYN); this contains (a) buffer space available (b) max incoming segment size (c) initial sequence number 2. “server” replies (SYN), same data. 3. “client” acks the SYN, begins sending data

  20. TCP connection establishment client server syn syn ack

  21. TCP data transfer • each side sends data within parameter limits (window, sequencing, acks) • two main classes of data : bulk and interactive • connection may remain open for considerable time (hours) • when each side has no more data to send, connection is closed

  22. TCP connection termination • normal case - initiated by either side A : “finished, no more data to send” (FIN bit set) B : ack B : when done sending data, sets FIN bit A : acks • abnormal case - RST bit set, closes connection immediately

More Related