19-1 Last time □ TCP ♦ Throughput ♦ Fairness ♦ Delay modeling □ TCP socket programming.

Slides:



Advertisements
Similar presentations
CPSC Network Layer4-1 IP addresses: how to get one? Q: How does a host get IP address? r hard-coded by system admin in a file m Windows: control-panel->network->configuration-
Advertisements

CS 457 – Lecture 16 Global Internet - BGP Spring 2012.
Week 5: Internet Protocol Continue to discuss Ethernet and ARP –MTU –Ethernet and ARP packet format IP: Internet Protocol –Datagram format –IPv4 addressing.
Application Layer 2-1 Chapter 2 Application Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Application Layer – Lecture.
Application Layer-11 CSE401N: Computer Networks Lecture-4 Application Layer Overview HTTP.
Application Layer  We will learn about protocols by examining popular application-level protocols  HTTP  FTP  SMTP / POP3 / IMAP  Focus on client-server.
2: Application Layer1 Chapter 2: Application Layer Our goals: r conceptual, implementation aspects of network application protocols m transport-layer service.
Chapter 2: Application Layer
NAT: Network Address Translation local network (e.g., home network) /24 rest of Internet Datagrams.
1 Application Layer. 2 Writing Networked Applications TCP UDP IP LL PL TCP UDP IP LL PL TCP UDP IP LL PL Web Browser Web Server Ftp Server Ftp Client.
1 Creating a network app Write programs that m run on different end systems and m communicate over a network. m e.g., Web: Web server software communicates.
2: Application Layer1 Chapter 2 Application Layer Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross.
Application Layer Overview and Web/HTTP
Some slides are in courtesy of J. Kurose and K. Ross Review of Previous Lecture Network access and physical media Internet structure and ISPs Delay & loss.
Chapter 2 Application Layer Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross Addison-Wesley, July.
Week 11: Application Layer1 Week 11: Application layer r 2.1 Principles of network applications r 2.2 Web and HTTP r 2.3 FTP r 2.4 Electronic Mail  SMTP,
Introduction to the Application Layer Computer Networks Computer Networks Spring 2012 Spring 2012.
2: Application Layer1 Chapter 2: Application Layer Our goals: r conceptual, implementation aspects of network application protocols m transport-layer service.
Chapter 2 Application Layer slides are modified from J. Kurose & K. Ross CPE 400 / 600 Computer Communication Networks Lecture 4.
1 Computer Networks Transport Layer Protocols. 2 Application-layer Protocols Application-layer protocols –one “piece” of an app –define messages exchanged.
Application Layer  We will learn about protocols by examining popular application-level protocols  HTTP  FTP  SMTP / POP3 / IMAP  Focus on client-server.
EEC-484/584 Computer Networks Lecture 4 Wenbing Zhao (Part of the slides are based on Drs. Kurose & Ross ’ s slides for their Computer.
Some slides are in courtesy of J. Kurose and K. Ross Review of Previous Lecture Network access and physical media Internet structure and ISPs Delay & loss.
Dr. Philip Cannata 1 Principles of Network Applications.
Introduction 1 Lecture 5 Application Layer slides are modified from J. Kurose & K. Ross University of Nevada – Reno Computer Science & Engineering Department.
Chapter 2, slide: 1 ECE/CS 372 – introduction to computer networks Lecture 5 Announcements: r Lab1 is due today r Lab2 is posted and is due next Tuesday.
Chapter 2 Application Layer Computer Networking: A Top Down Approach, 5 th edition. Jim Kurose, Keith Ross Addison-Wesley, April A note on the use.
Chapter 2, slide: 1 CS 372 – introduction to computer networks* Monday June 28 Announcements: r Lab 1 is due today r Lab 2 is posted today and is due next.
2: Application Layer1 Chapter 2 Application Layer These slides derived from Computer Networking: A Top Down Approach, 6 th edition. Jim Kurose, Keith Ross.
Network Layer4-1 NAT: Network Address Translation local network (e.g., home network) /24 rest of.
Throughput: Internet scenario
Application Layer 2-1 Chapter 2 Application Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012.
2: Application Layer1 Some network apps r r Web r Instant messaging r Remote login r P2P file sharing r Multi-user network games r Streaming stored.
CHAPTER 2. Creating a network app write programs that – run on (different) end systems – communicate over network – e.g., web server software communicates.
1 Application Layer Lecture 4 Imran Ahmed University of Management & Technology.
CS 3830 Day 7 Introduction : Application Layer 2 Processes communicating Process: program running within a host. r within same host, two processes.
CS 3214 Computer Systems Godmar Back Lecture 24 Supplementary Material.
1 CS 455/555 Intro to Networks and Communications Client/Server Computing and Socket Programming (2.1, ) Michele Weigle Department of Computer Science.
1 Computer Communication & Networks Lecture 28 Application Layer: HTTP & WWW p Waleed Ejaz
1 NAT Network Address Translation Motivation for NAT To solve the insufficient problem of IP addresses IPv6 –All software and hardware need to be updated.
Network Layer4-1 DHCP: Dynamic Host Configuration Protocol Goal: allow host to dynamically obtain its IP address from network server when it joins network.
What makes a network good? Ch 2.1: Principles of Network Apps 2: Application Layer1.
Transport Layer 3-1 Chapter 4 Network Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012  CPSC.
2: Application Layer 1 Chapter 2: Application layer r 2.1 Principles of network applications r 2.2 Web and HTTP r 2.3 FTP r 2.4 Electronic Mail  SMTP,
2: Application Layer1 Chapter 2 Application Layer Computer Networking: A Top Down Approach, 4 th edition. Jim Kurose, Keith Ross Addison-Wesley, July 2007.
Network Layer4-1 Chapter 4: Network Layer r 4. 1 Introduction r 4.2 Virtual circuit and datagram networks r 4.3 What’s inside a router r 4.4 IP: Internet.
Sockets process sends/receives messages to/from its socket
1 End-user Protocols, Services and QoS. 2 Layering: logical communication application transport network link physical application transport network link.
Application Layer 2-1 Chapter 2 Application Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012.
Transport Layer3-1 Chapter 4: Network Layer r 4. 1 Introduction r 4.2 Virtual circuit and datagram networks r 4.3 What’s inside a router r 4.4 IP: Internet.
2: Application Layer1 Chapter 2 Application Layer Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross.
Lecture 23 Application Layer ELEN E6761: Communication Networks Instructor: Javad Ghaderi Slides adapted from “Computer Networking: A Top Down Approach”
2: Application Layer 1 Application layer  Principles of network applications  Web and HTTP  FTP, TFTP  TELNET  Electronic Mail  SMTP, POP3, IMAP.
2: Application Layer 1 Chapter 2 Application Layer Computer Networking: A Top Down Approach, 5 th edition. Jim Kurose, Keith Ross Addison-Wesley, April.
Important r There will be NO CLASS on Friday 1/30/2015! r Please mark you calendars 1.
2: Application Layer 1 Chapter 2: Application layer r 2.1 Principles of network applications  app architectures  app requirements r 2.2 Web and HTTP.
1 Chapter 2: Application Layer Part A Introduction r 2.1 Principles of network applications r 2.2 Web and HTTP r 2.3 FTP.
Data Communications and Computer Networks Chapter 2 CS 3830 Lecture 7 Omar Meqdadi Department of Computer Science and Software Engineering University of.
Data Communications and Computer Networks Chapter 4 CS 3830 Lecture 19 Omar Meqdadi Department of Computer Science and Software Engineering University.
@Yuan Xue CS 283Computer Networks Spring 2011 Instructor: Yuan Xue.
Chapter 7 Application Layer 1 Some of the slides in this chapter are courtesy of Profs. Kurose/Ross and others.
A special acknowledge goes to J.F Kurose and K.W. Ross Some of the slides used in this lecture are adapted from their original slides that accompany the.
Network Address Translation
Internet transport protocols services
Chapter 2 Application Layer
Introduction to Networks
Chapter 2 Introduction Application Requirements VS. Transport Services
Computer Communication & Networks
Session 3 INST 346 Technologies, Infrastructure and Architecture
Presentation transcript:

19-1 Last time □ TCP ♦ Throughput ♦ Fairness ♦ Delay modeling □ TCP socket programming

19-2 This time □ NAT □ Application layer ♦ Intro ♦ Web / HTTP

19-3 Chapter 4: Network Layer □ 4. 1 Introduction □ 4.2 Virtual circuit and datagram networks □ 4.3 What’s inside a router □ 4.4 IP: Internet Protocol ♦ Datagram format ♦ IPv4 addressing ♦ ICMP ♦ IPv6 □ 4.5 Routing algorithms ♦ Link state ♦ Distance Vector ♦ Hierarchical routing □ 4.6 Routing in the Internet ♦ RIP ♦ OSPF ♦ BGP □ 4.7 Broadcast and multicast routing

19-4 NAT: Network Address Translation local network (e.g., home network) /24 rest of Internet Datagrams with source or destination in this network have /24 address for source, destination (as usual) All datagrams leaving local network have same single source NAT IP address: , different source port numbers

19-5 NAT: Network Address Translation □ Motivation: local network uses just one IP address as far as outside world is concerned: ♦ range of addresses not needed from ISP: just one IP address for all devices ♦ can change addresses of devices in local network without notifying outside world ♦ can change ISP without changing addresses of devices in local network ♦ devices inside local net not explicitly addressable, visible by outside world (a security plus).

19-6 NAT: Network Address Translation Implementation: NAT router must: ♦ outgoing datagrams: replace (source IP address, port #) of every outgoing datagram to (NAT IP address, new port #)... remote clients/servers will respond using (NAT IP address, new port #) as destination addr. ♦ remember (in NAT translation table) every (source IP address, port #) to (NAT IP address, new port #) translation pair ♦ incoming datagrams: replace (NAT IP address, new port #) in dest fields of every incoming datagram with corresponding (source IP address, port #) stored in NAT table

19-7 NAT: Network Address Translation S: , 3345 D: , : host sends datagram to , 80 NAT translation table WAN side addr LAN side addr , , 3345 …… S: , 80 D: , S: , 5001 D: , : NAT router changes datagram source addr from , 3345 to , 5001, updates table S: , 80 D: , : Reply arrives dest. address: , : NAT router changes datagram dest addr from , 5001 to , 3345

19-8 NAT: Network Address Translation □ 16-bit port-number field: ♦ 60,000 simultaneous connections with a single LAN-side address! □ NAT is controversial: ♦ routers should only process up to layer 3 ♦ violates end-to-end argument NAT possibility must be taken into account by app designers, eg, P2P applications ♦ address shortage should instead be solved by IPv6

19-9 Chapter 2: Application layer □ 2.1 Principles of network applications □ 2.2 Web and HTTP □ 2.3 FTP □ 2.4 Electronic Mail ♦ SMTP, POP3, IMAP □ 2.5 DNS □ 2.6 P2P file sharing □ 2.7 Socket programming with TCP □ 2.8 Socket programming with UDP □ 2.9 Building a Web server

19-10 Some network apps □ □ Web □ Instant messaging □ Remote login □ P2P file sharing □ Multi-user network games □ Streaming stored video clips □ Internet telephone □ Real-time video conference □ Massive parallel computing

19-11 Creating a network app Write programs that ♦ run on different end systems and ♦ communicate over a network. ♦ e.g., Web: Web server software communicates with browser software Little software written for devices in network core ♦ network core devices do not run user application code ♦ application on end systems allows for rapid app development, propagation application transport network data link physical application transport network data link physical application transport network data link physical

19-12 Chapter 2: Application layer □ 2.1 Principles of network applications □ 2.2 Web and HTTP □ 2.3 FTP □ 2.4 Electronic Mail ♦ SMTP, POP3, IMAP □ 2.5 DNS □ 2.6 P2P file sharing □ 2.7 Socket programming with TCP □ 2.8 Socket programming with UDP □ 2.9 Building a Web server

19-13 Application architectures □ Client-server □ Peer-to-peer (P2P) □ Hybrid of client-server and P2P

19-14 Client-server architecture server: ♦ always-on host ♦ permanent IP address ♦ server farms for scaling clients: ♦ communicate with server ♦ may be intermittently connected ♦ may have dynamic IP addresses ♦ do not communicate directly with each other

19-15 Pure P2P architecture □ no always-on server □ arbitrary end systems directly communicate □ peers are intermittently connected and change IP addresses □ example: Gnutella Highly scalable but difficult to manage

19-16 Hybrid of client-server and P2P Skype ♦ Internet telephony app ♦ Finding address of remote party: centralized server(s) ♦ Client-client connection is direct (not through server) Instant messaging ♦ Chatting between two users can be P2P ♦ Presence detection/location centralized: User registers its IP address with central server when it comes online User contacts central server to find IP addresses of buddies

19-17 Processes communicating Process: program running within a host. □ within same host, two processes communicate using inter-process communication (defined by OS). □ processes in different hosts communicate by exchanging messages Client process: process that initiates communication Server process: process that waits to be contacted □ Note: applications with P2P architectures have client processes & server processes

19-18 App-layer protocol defines □ Types of messages exchanged, ♦ e.g., request, response □ Message syntax: ♦ what fields in messages & how fields are delineated □ Message semantics ♦ meaning of information in fields □ Rules for when and how processes send & respond to messages Public-domain protocols: □ defined in RFCs □ allows for interoperability □ e.g., HTTP, SMTP Proprietary protocols: □ e.g., KaZaA

19-19 What transport service does an app need? Data loss □ some apps (e.g., audio) can tolerate some loss □ other apps (e.g., file transfer, telnet) require 100% reliable data transfer Timing □ some apps (e.g., Internet telephony, interactive games) require low delay to be “effective” Bandwidth □ some apps (e.g., multimedia) require minimum amount of bandwidth to be “effective” □ other apps (“elastic apps”) make use of whatever bandwidth they get

19-20 Transport service requirements of common apps Application file transfer Web documents real-time audio/video stored audio/video interactive games instant messaging Data loss no loss loss-tolerant no loss Bandwidth elastic audio: 5kbps-1Mbps video:10kbps-5Mbps same as above few kbps up elastic Time Sensitive no yes, 100’s msec yes, few secs yes, 100’s msec yes and no

19-21 Internet transport protocols services TCP service: □ connection-oriented: setup required between client and server processes □ reliable transport between sending and receiving process □ flow control: sender won’t overwhelm receiver □ congestion control: throttle sender when network overloaded □ does not provide: timing, minimum bandwidth guarantees UDP service: □ unreliable data transfer between sending and receiving process □ does not provide: connection setup, reliability, flow control, congestion control, timing, or bandwidth guarantee Q: why bother? Why is there a UDP?

19-22 Internet apps: application, transport protocols Application remote terminal access Web file transfer streaming multimedia Internet telephony Application layer protocol SMTP [RFC 2821] Telnet [RFC 854] HTTP [RFC 2616] FTP [RFC 959] proprietary (e.g. RealNetworks) proprietary (e.g., Vonage,Dialpad) Underlying transport protocol TCP TCP or UDP typically UDP

19-23 Chapter 2: Application layer □ 2.1 Principles of network applications ♦ app architectures ♦ app requirements □ 2.2 Web and HTTP □ 2.4 Electronic Mail ♦ SMTP, POP3, IMAP □ 2.5 DNS □ 2.6 P2P file sharing □ 2.7 Socket programming with TCP □ 2.8 Socket programming with UDP □ 2.9 Building a Web server

19-24 Web and HTTP First some jargon □ Web page consists of objects □ Object can be HTML file, JPEG image, Java applet, audio file,… □ Web page consists of base HTML-file which includes several referenced objects □ Each object is addressable by a URL □ Example URL: host name path name

19-25 HTTP overview HTTP: hypertext transfer protocol □ Web’s application layer protocol □ client/server model ♦ client: browser that requests, receives, “displays” Web objects ♦ server: Web server sends objects in response to requests □ HTTP 1.0: RFC 1945 □ HTTP 1.1: RFC 2068 PC running Explorer Server running Apache Web server Mac running Navigator HTTP request HTTP response

19-26 HTTP overview (continued) Uses TCP: □ client initiates TCP connection (creates socket) to server, port 80 □ server accepts TCP connection from client □ HTTP messages (application- layer protocol messages) exchanged between browser (HTTP client) and Web server (HTTP server) □ TCP connection closed HTTP is “stateless” □ server maintains no information about past client requests Protocols that maintain “state” are complex! □ past history (state) must be maintained □ if server/client crashes, their views of “state” may be inconsistent, must be reconciled aside

19-27 HTTP connections Nonpersistent HTTP □ At most one object is sent over a TCP connection. □ HTTP/1.0 uses nonpersistent HTTP Persistent HTTP □ Multiple objects can be sent over single TCP connection between client and server. □ HTTP/1.1 uses persistent connections in default mode

19-28 Nonpersistent HTTP Suppose user enters URL 1a. HTTP client initiates TCP connection to HTTP server (process) at on port HTTP client sends HTTP request message (containing URL) into TCP connection socket. Message indicates that client wants object /someDept/home.index 1b. HTTP server at host waiting for TCP connection at port 80. “accepts” connection, notifying client 3. HTTP server receives request message, forms response message containing requested object, and sends message into its socket time (contains text, references to 10 jpeg images)

19-29 Nonpersistent HTTP (cont.) 5. HTTP client receives response message containing html file, displays html. Parsing html file, finds 10 referenced jpeg objects 6. Steps 1-5 repeated for each of 10 jpeg objects 4. HTTP server closes TCP connection. time

19-30 Non-Persistent HTTP: Response time Definition of RTT: time to send a small packet to travel from client to server and back. Response time: □ one RTT to initiate TCP connection □ one RTT for HTTP request and first few bytes of HTTP response to return □ file transmission time total = 2RTT+transmit time time to transmit file initiate TCP connection RTT request file RTT file received time

19-31 Persistent HTTP Nonpersistent HTTP issues: □ requires 2 RTTs per object □ OS overhead for each TCP connection □ browsers often open parallel TCP connections to fetch referenced objects Persistent HTTP □ server leaves connection open after sending response □ subsequent HTTP messages between same client/server sent over open connection Persistent without pipelining: □ client issues new request only when previous response has been received □ one RTT for each referenced object Persistent with pipelining: □ default in HTTP/1.1 □ client sends requests as soon as it encounters a referenced object □ as little as one RTT for all the referenced objects

19-32 Recap □ NAT □ Application layer ♦ Intro ♦ Web / HTTP

19-33 Next time □ Finish HTTP □ FTP □ SMTP ( )