CS 5565 Network Architecture and Protocols

Slides:



Advertisements
Similar presentations
CS144 Review Session 4 April 25, 2008 Ben Nham
Advertisements

Introduction 1 Lecture 13 Transport Layer (Transmission Control Protocol) slides are modified from J. Kurose & K. Ross University of Nevada – Reno Computer.
2: Transport Layer 31 Transport Layer 3. 2: Transport Layer 32 TCP Flow Control receiver: explicitly informs sender of (dynamically changing) amount of.
1 Transport Protocols & TCP CSE 3213 Fall April 2015.
Transportation Layer (2). TCP full duplex data: – bi-directional data flow in same connection – MSS: maximum segment size connection-oriented: – handshaking.
Transport Layer – TCP (Part2) Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF.
Fundamentals of Computer Networks ECE 478/578 Lecture #20: Transmission Control Protocol Instructor: Loukas Lazos Dept of Electrical and Computer Engineering.
Transport Layer3-1 TCP. Transport Layer3-2 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional data flow in same connection.
Data Communications and Computer Networks Chapter 3 CS 3830 Lecture 16 Omar Meqdadi Department of Computer Science and Software Engineering University.
1 Chapter 3 Transport Layer. 2 Chapter 3 outline 3.1 Transport-layer services 3.2 Multiplexing and demultiplexing 3.3 Connectionless transport: UDP 3.4.
1 Transport Layer Lecture 9 Imran Ahmed University of Management & Technology.
Transport Layer3-1 Summary of Reliable Data Transfer Checksums help us detect errors ACKs and NAKs help us deal with errors If ACK/NAK has errors sender.
Week 9 TCP9-1 Week 9 TCP 3 outline r 3.5 Connection-oriented transport: TCP m segment structure m reliable data transfer m flow control m connection management.
Transport Layer1 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r reliable, in-order byte steam: m no “message boundaries” r pipelined: m TCP congestion.
Announcement Homework 2 in tonight –Will be graded and sent back before Th. class Midterm next Tu. in class –Review session next time –Closed book –One.
EEC-484/584 Computer Networks Lecture 15 Wenbing Zhao (Part of the slides are based on Drs. Kurose & Ross ’ s slides for their Computer.
Announcement Project 2 finally ready on Tlab Homework 2 due next Mon tonight –Will be graded and sent back before Tu. class Midterm next Th. in class –Review.
Transport Layer Transport Layer: TCP. Transport Layer 3-2 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional.
1 Announcement r Project 2 out m Much harder than project 1, start early! r Homework 2 due next Tuesday.
Chapter 3 Transport Layer
The Transport Layer Chapter 6. The Transport Service Services Provided to the Upper Layers Transport Service Primitives Berkeley Sockets An Example of.
Transport Layer3-1 Data Communication and Networks Lecture 7 Transport Protocols: TCP October 21, 2004.
EEC-484/584 Computer Networks Lecture 13 Wenbing Zhao (Part of the slides are based on Drs. Kurose & Ross ’ s slides for their Computer.
1 Ch. 7 : Internet Transport Protocols. Transport Layer Our goals: r understand principles behind transport layer services: m Multiplexing / demultiplexing.
TCP. Learning objectives Reliable Transport in TCP TCP flow and Congestion Control.
EEC-484/584 Computer Networks Lecture 16 Wenbing Zhao (Part of the slides are based on Drs. Kurose & Ross ’ s slides for their Computer.
Transport Layer3-1 TCP sender (simplified) NextSeqNum = InitialSeqNum SendBase = InitialSeqNum loop (forever) { switch(event) event: data received from.
3: Transport Layer3b-1 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional data flow in same connection m MSS: maximum.
TCOM 509 – Internet Protocols (TCP/IP) Lecture 04_b Transport Protocols - TCP Instructor: Dr. Li-Chuan Chen Date: 09/22/2003 Based in part upon slides.
17-1 Last time □ UDP socket programming ♦ DatagramSocket, DatagramPacket □ TCP ♦ Sequence numbers, ACKs ♦ RTT, DevRTT, timeout calculations ♦ Reliable.
The Transport Layer.
The Transport Layer Chapter 6. The Transport Service The transport layer is the heart of the whole protocol hierarchy It provides reliable data transport.
Transport Layer3-1 Chapter 3: Transport Layer Our goals: r understand principles behind transport layer services: m multiplexing/demultipl exing m reliable.
Transport Layer3-1 Transport Layer Our lives begin to end, the day we become silent about things that matter.
September 26 th, 2013 CS1652 The slides are adapted from the publisher’s material All material copyright J.F Kurose and K.W. Ross, All Rights.
ECE 4110 – Internetwork Programming
CS 5565 Network Architecture and Protocols Godmar Back Lecture 14.
IP Configuration API. Network Interface Configuration NAIfconfigIsDeviceUp() NAIfconfigDeviceFromInterface() NAIfconfigBringDeviceUp() NAIfconfigSetIpAddress()
Transport Layer3-1 Chapter 3 outline r 3.1 Transport-layer services r 3.2 Multiplexing and demultiplexing r 3.3 Connectionless transport: UDP r 3.4 Principles.
Transport Layer1 TCP Connection Management Recall: TCP sender, receiver establish “connection” before exchanging data segments r initialize TCP variables:
IT 424 Networks2 IT 424 Networks2 Ack.: Slides are adapted from the slides of the book: “Computer Networking” – J. Kurose, K. Ross Chapter 3: Transport.
11 CS716 Advanced Computer Networks By Dr. Amir Qayyum.
09-Transport Layer: TCP Transport Layer.
The Transport Layer TCP
COMP 431 Internet Services & Protocols
DMET 602: Networks and Media Lab
Fast Retransmit For sliding windows flow control we waited for a timer to expire before beginning retransmission of a packet TCP uses an additional mechanism.
CS 1652 Jack Lange University of Pittsburgh
The Transport Layer (TCP)
Chapter 15 Transmission Control Protocol (TCP)
5. End-to-end protocols (part 1)
Chapter 17 and 18: TCP is connection oriented
TCP.
CS1652 TCP Jack Lange University of Pittsburgh
Chapter 6: Transport Layer (Part I)
Review: UDP demultiplexing TCP demultiplexing Multiplexing?
Computer Networks Bhushan Trivedi, Director, MCA Programme, at the GLS Institute of Computer Technology, Ahmadabad.
CS 5565 Network Architecture and Protocols
TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 15 Transmission Control Protocol.
CS4470 Computer Networking Protocols
Chapter 3 outline 3.1 Transport-layer services
CS 5565 Network Architecture and Protocols
Transportation Layer.
TCP - Part I Relates to Lab 5. First module on TCP which covers packet format, data transfer, and connection management.
Transport Protocols: TCP Segments, Flow control and Connection Setup
The Transport Layer Chapter 6.
Transport Protocols: TCP Segments, Flow control and Connection Setup
Process-to-Process Delivery: UDP, TCP
TCP Connection Management
Chapter 3 Transport Layer
Presentation transcript:

CS 5565 Network Architecture and Protocols Lecture 12 Godmar Back

Announcements Problem Set 2 due Mar 18 Project 1B due Mar 20 Reminder: can be done as a team, can switch teams between projects, use forum if you’re looking for team members Midterm April 1 (no joke) Required Reading: DCCP by Koehler et al, SIGCOMM 2006 CS 5565 Spring 2009 11/28/2018

Study of TCP: Outline segment structure reliable data transfer delayed ACKs Nagle’s algorithm timeout management, fast retransmit flow control + silly window syndrome connection management [ Network Address Translation ] [ Principles of congestion control ] TCP congestion control CS 5565 Spring 2009 11/28/2018

Connection Management TCP Connection Management

TCP Connection Management Recall: TCP sender, receiver establish “connection” before exchanging data segments initialize TCP variables: seq. #s buffers, flow control info (e.g. RcvWindow) client: connection initiator connect(s, &dstaddr, …) server: contacted by client cl=accept(sv, &caddr,…); Three way handshake: Step 1: client host sends TCP SYN segment to server specifies initial seq # no data Step 2: server host receives SYN, replies with SYNACK segment server allocates buffers specifies server initial seq. # Step 3: client receives SYNACK, replies with ACK segment, which may contain data CS 5565 Spring 2009 11/28/2018

TCP 3-way handshake TCP connection establishment: Q1: why 3-way and not 2-way handshake? Q2: how do sender & receiver determine initial seqnums? CS 5565 Spring 2009 11/28/2018

3-way Handshake & Delayed Dups Normal operation Old SYN appearing out of nowhere. Duplicate SYN and duplicate ACK following SYN. 3-way handshake required to deal with scenarios (b) and (c) CS 5565 Spring 2009 11/28/2018

Sequence Number Reuse Idea: Tie initial TCP seq numbers to clock Increment every 4s, guards against previous incarnations of a connection with identical sequence numbers Must also guard against sequence number prediction attack Use PRNG see [RFC 1948], [CERT 2001-09] RFC 1948: ISN = 4s clock val + F(src, dst, sport, dport, random()) CS 5565 Spring 2009 11/28/2018

When Sequence Numbers Attack Suppose attacker A can predict sequence number a host B is going to use next By using spoofed source IP C, A can engage in successful 3-way handshake with B B believes it is talking to C, might grant permissions based on C’s IP address Attacker on A must suppress the RST packets C is likely to send – use a denial-of-service attack for that A sends message to compromise B CS 5565 Spring 2009 11/28/2018

When SYNs Attack Servers receiving SYN must allocate resources Opens up possibility of denial-of-service attack where server is flooded with bogus SYN packets with forged IP source addresses Solution: SYN cookies Server creates ACK number, sends ACK – but does not allocate buffers If client continues with SYNACK, check if ACK could have been sent, then allocate buffers if correct CS 5565 Spring 2009 11/28/2018

TCP Connection Management (cont.) Closing a connection: client closes socket: close(s); Step 1: client end system sends TCP FIN control segment to server Step 2: server receives FIN, replies with ACK. Closes connection, sends FIN. client FIN server ACK close closed timed wait CS 5565 Spring 2009 11/28/2018

TCP Connection Management (cont.) Step 3: client receives FIN, replies with ACK. Enters “timed wait” - will respond with ACK to received FINs Step 4: server, receives ACK. Connection closed. Note: with small modification, can handle simultaneous FINs. client server closing FIN ACK closing FIN ACK timed wait closed closed CS 5565 Spring 2009 11/28/2018

TCP Connection FSM The heavy solid line is the normal path for a client. The heavy dashed line is the normal path for a server. The light lines are unusual events. Each transition is labeled by the event causing it and the action resulting from it, separated by a slash. CS 5565 Spring 2009 11/28/2018

TCP Connection Management (cont’d) TCP client lifecycle TCP server lifecycle CS 5565 Spring 2009 11/28/2018

Closing a Connection Note: previous charts showed normal case Can we reliably close a connection if packets (FIN, ACK) can be lost? No: Famous two-army problem CS 5565 Spring 2009 11/28/2018

Summary TCP segments, acknowledgements & retransmission Delayed ACKs, Nagle’s algorithm Fast retransmit RTT estimation & Karn’s algorithm Flow Control & Silly Window Syndrome Connection Management in TCP Attacks against TCP’s connection management scheme SYN attack Sequence number prediction attacks CS 5565 Spring 2009 11/28/2018

TCP Miscellaneous MSS Maximum Segment Size Option Client/server agree on larger than default (536 outside same subnet) MSS, option on SYN SACK – selective acknowledgements WSCALE – scale factor for receive window to allow for LFN (“elefant”) – Large Fat Networks RFC 1323 timestamps for accurate RTT measurement, PAWS for protection against wrap-around for sequence numbers … CS 5565 Spring 2009 11/28/2018