Chapter 2: outline. 2.6 P2P applications 2.7 socket programming with UDP and TCP

Size: px
Start display at page:

Download "Chapter 2: outline. 2.6 P2P applications 2.7 socket programming with UDP and TCP"

Transcription

1 Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming with UDP and TCP Application Layer 2-1

2 FTP: the file transfer protocol client/server model based on TCP, port 21 separate control and data connections FTP server maintains states commands in ASCII text Application Layer 2-2

3 FTP mode Passive mode: client initiates data connection. Client sends PASV command to request server side port number. Active mode: server initiates the data connection. Client sends PORT command to specify the client side port number. Application Layer 2-3

4 Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming with UDP and TCP Application Layer 2-4

5 Electronic Mail SMTP client/server model based on TCP, port 25 three phases of transfer: handshaking, transfer of messages, closure commands and messages in ASCII text Mail message format defined in RFC 822 header and body POP3 and IMAP mail access protocols 2: Application Layer 5

6 Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming with UDP and TCP Application Layer 2-6

7 DNS: Domain Name System hierarchical distributed database for name-ip translation DNS services hostname to IP address translation host aliasing: canonical, alias names mail server aliasing load distribution 2: Application Layer 7

8 Distributed, Hierarchical Database Root DNS Servers com DNS servers org DNS servers edu DNS servers yahoo.com DNS servers amazon.com DNS servers pbs.org DNS servers poly.edu umass.edu DNS serversdns servers Root name servers Top-level domain (TLD) servers Authoritative DNS servers Local name server 2: Application Layer 8

9 DNS name resolution example root DNS server host at cis.poly.edu wants IP address for gaia.cs.umass.edu TLD DNS server iterated query: contacted server replies with name of server to contact I don t know this name, but ask this server local DNS server dns.poly.edu 1 8 requesting host cis.poly.edu 7 6 authoritative DNS server dns.cs.umass.edu gaia.cs.umass.edu Application Layer 2-9

10 DNS name resolution example root DNS server recursive query: puts burden of name resolution on contacted name server local DNS server dns.poly.edu 5 4 TLD DNS server heavy load at upper levels of hierarchy 1 8 requesting host cis.poly.edu authoritative DNS server dns.cs.umass.edu gaia.cs.umass.edu Application Layer 2-10

11 DNS: caching, updating records once (any) name server learns mapping, it caches mapping cache entries timeout (disappear) after some time (TTL) TLD servers typically cached in local name servers cached entries may be out-of-date (best effort name-to-address translation!) if name host changes IP address, may not be known Internet-wide until all TTLs expire Application Layer 2-11

12 DNS records DNS: distributed db storing resource records (RR) RR format: (name, value, type, ttl) type=a name is hostname value is IP address type=ns name is domain (e.g., foo.com) value is hostname of authoritative name server for this domain type=cname name is alias name for some canonical (the real) name is really servereast.backup2.ibm.com value is canonical name type=mx value is name of mailserver associated with name Application Layer 2-12

13 DNS protocol, messages query and reply messages, both with same message format 2 bytes 2 bytes msg header identification flags identification # questions # authority RRs flags # answer RRs # additional RRs msg body four sections questions (variable # of questions) answers (variable # of RRs) authority (variable # of RRs) additional info (variable # of RRs) Application Layer 2-13

14 Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming with UDP and TCP Application Layer 2-14

15 Client-server vs. P2P: example client upload rate = u, F/u = 1 hour, u s = 10u, d min u s Minimum Distribution Time P2P Client-Server D c-s > max{nf/u s,,f/d min } D P2P > max{f/u s,,f/d min,,nf/(u s + Su i )} N Application Layer 2-15

16 P2P file distribution: BitTorrent file divided into 256Kb chunks peers in torrent send/receive file chunks tracker: tracks peers participating in torrent torrent: group of peers exchanging chunks of a file Alice arrives obtains list of peers from tracker and begins exchanging file chunks with peers in torrent Application Layer 2-16

17 BitTorrent: requesting, sending file chunks requesting chunks: at any given time, different peers have different subsets of file chunks periodically, Alice asks each peer for list of chunks that they have Alice requests missing chunks from peers, rarest first sending chunks: tit-for-tat Alice sends chunks to those four peers currently sending her chunks at highest rate other peers are choked by Alice (do not receive chunks from her) re-evaluate top 4 every10 secs every 30 secs: randomly select another peer, starts sending chunks optimistically unchoke this peer newly chosen peer may join top 4 Application Layer 2-17

18 Distributed Hash Table (DHT) DHT = distributed P2P database Database has (key, value) pairs; key: content type; value: IP address Peers query DB with key DB returns values that match the key Central issue: Assigning (key, value) pairs to peers.

19 Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming with UDP and TCP Application Layer 2-19

20 Socket programming goal: learn how to build client/server applications that communicate using sockets socket: door between application process and endend-transport protocol application process socket application process controlled by app developer transport network link physical Internet transport network link physical controlled by OS Application Layer 2-20

21 Socket programming Two socket types for two transport services: UDP: unreliable datagram TCP: reliable, byte stream-oriented Application Example: 1. Client reads a line of characters (data) from its keyboard and sends the data to the server. 2. The server receives the data and converts characters to uppercase. 3. The server sends the modified data to the client. 4. The client receives the modified data and displays the line on its screen. Application Layer 2-21

22 Socket programming with UDP UDP: no connection between client & server no handshaking before sending data sender explicitly attaches IP destination address and port # to each packet rcvr extracts sender IP address and port# from received packet UDP: transmitted data may be lost or received out-of-order Application viewpoint: UDP provides unreliable transfer of groups of bytes ( datagrams ) between client and server Application Layer 2-22

23 Client/server socket interaction: UDP server (running on serverip) create socket, port= x: serversocket = socket(af_inet,sock_dgram) read datagram from serversocket write reply to serversocket specifying client address, port number client create socket: clientsocket = socket(af_inet,sock_dgram) Create datagram with server IP and port=x; send datagram via clientsocket read datagram from clientsocket close clientsocket Application 2-23

24 Example app: UDP client Python UDPClient include Python s socket library from socket import * servername = hostname serverport = create UDP socket for server get user keyboard input Attach server name, port to message; send into socket read reply characters from socket into string print out received string and close socket clientsocket = socket(af_inet, SOCK_DGRAM) message = raw_input( Input lowercase sentence: ) clientsocket.sendto(message,(servername, serverport)) modifiedmessage, serveraddress = clientsocket.recvfrom(1024) print modifiedmessage clientsocket.close() Application Layer 2-24

25 Example app: UDP server create UDP socket bind socket to local port number loop forever Read from UDP socket into message, getting client s address (client IP and port) send upper case string back to this client Python UDPServer from socket import * serverport = serversocket = socket(af_inet, SOCK_DGRAM) serversocket.bind(('', serverport)) print The server is ready to receive while 1: message, clientaddress = serversocket.recvfrom(1024) modifiedmessage = message.upper() serversocket.sendto(modifiedmessage, clientaddress) Application Layer 2-25

26 Socket programming with TCP client must contact server server process must first be running server must have created socket (door) that welcomes client s contact client contacts server by: Creating TCP socket, specifying IP address, port number of server process when client creates socket: client TCP establishes connection to server TCP when contacted by client, server TCP creates new socket for server process to communicate with that particular client allows server to talk with multiple clients source port numbers used to distinguish clients (more in Chap 3) application viewpoint: TCP provides reliable, in-order byte-stream transfer ( pipe ) between client and server Application Layer 2-26

27 Client/server socket interaction: TCP server (running on hostid) client create socket, port=x, for incoming request: serversocket = socket() wait for incoming connection request connectionsocket = serversocket.accept() read request from connectionsocket write reply to connectionsocket close connectionsocket TCP connection setup create socket, connect to hostid, port=x clientsocket = socket() send request using clientsocket read reply from clientsocket close clientsocket Application Layer 2-27

28 Example app: TCP client create TCP socket for server, remote port No need to attach server name, port Python TCPClient from socket import * servername = servername serverport = clientsocket = socket(af_inet, SOCK_STREAM) clientsocket.connect((servername,serverport)) sentence = raw_input( Input lowercase sentence: ) clientsocket.send(sentence) modifiedsentence = clientsocket.recv(1024) print From Server:, modifiedsentence clientsocket.close() Application Layer 2-28

29 Example app: TCP server Python TCPServer create TCP welcoming socket server begins listening for incoming TCP requests loop forever server waits on accept() for incoming requests, new socket created on return read bytes from socket (but not address as in UDP) close connection to this client (but not welcoming socket) from socket import * serverport = serversocket = socket(af_inet,sock_stream) serversocket.bind((,serverport)) serversocket.listen(1) print The server is ready to receive while 1: connectionsocket, addr = serversocket.accept() sentence = connectionsocket.recv(1024) capitalizedsentence = sentence.upper() connectionsocket.send(capitalizedsentence) connectionsocket.close() Application Layer 2-29

30 Chapter 2: summary our study of network apps now complete! application architectures client-server P2P application service requirements: reliability, bandwidth, delay Internet transport service model connection-oriented, reliable: TCP unreliable, datagrams: UDP specific protocols: HTTP FTP SMTP, POP, IMAP DNS P2P: BitTorrent, DHT socket programming: TCP, UDP sockets Application Layer 2-30

31 Chapter 3 Transport Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 Slides adopted from original ones provided by the textbook authors. Transport Layer 3-31

32 Chapter 3: Transport Layer our goals: understand principles behind transport layer services: multiplexing, demultiplexing reliable data transfer flow control congestion control learn about Internet transport layer protocols: UDP: connectionless transport TCP: connection-oriented reliable transport TCP congestion control Transport Layer 3-32

33 Chapter 3 outline 3.1 transport-layer services 3.2 multiplexing and demultiplexing 3.3 connectionless transport: UDP 3.4 principles of reliable data transfer 3.5 connection-oriented transport: TCP segment structure reliable data transfer flow control connection management 3.6 principles of congestion control 3.7 TCP congestion control Transport Layer 3-33

34 Transport services and protocols provide logical communication between app processes running on different hosts transport protocols run in end systems send side: breaks app messages into segments, passes to network layer rcv side: reassembles segments into messages, passes to app layer more than one transport protocol available to apps Internet: TCP and UDP application transport network data link physical application transport network data link physical Transport Layer 3-34

35 Transport vs. network layer network layer: logical communication between hosts transport layer: logical communication between processes relies on, enhances, network layer services 12 kids in Ann s house sending letters to 12 kids in Bill s house: hosts = houses processes = kids app messages = letters in household analogy: envelopes transport protocol = Ann and Bill who demux to inhouse siblings network-layer protocol = postal service Transport Layer 3-35

36 Internet transport-layer protocols reliable, in-order delivery (TCP) congestion control flow control connection setup unreliable, unordered delivery: UDP no-frills extension of best-effort IP services not available: delay guarantees bandwidth guarantees application transport network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical application transport network data link physical Transport Layer 3-36

37 Example R6. Is it possible for an application to enjoy reliable data transfer even when the application runs over UDP? If so, how? Transport Layer 3-37

38 Chapter 3 outline 3.1 transport-layer services 3.2 multiplexing and demultiplexing 3.3 connectionless transport: UDP 3.4 principles of reliable data transfer 3.5 connection-oriented transport: TCP segment structure reliable data transfer flow control connection management 3.6 principles of congestion control 3.7 TCP congestion control Transport Layer 3-38

39 Multiplexing/demultiplexing multiplexing at sender: handle data from multiple sockets, add transport header (later used for demultiplexing) demultiplexing at receiver: use header info to deliver received segments to correct socket application application P3 transport network link P1 P2 transport network link physical application P4 transport network link socket process physical physical Transport Layer 3-39

40 How demultiplexing works host receives IP datagrams each datagram has source IP address, destination IP address each datagram carries one transport-layer segment each segment has source, destination port numbers host uses IP addresses & port numbers to direct segment to appropriate socket 32 bits source port # dest port # other header fields application data (payload) TCP/UDP segment format Transport Layer 3-40

41 Connectionless demultiplexing recall: created socket has host-local port #: serverport = when host receives UDP segment: checks destination port # in segment directs UDP segment to socket with that port # recall: when creating datagram to send into UDP socket, must specify destination IP address destination port # IP datagrams with same dest. port #, but different source IP addresses and/or source port numbers will be directed to same socket at dest Transport Layer 3-41

42 Connectionless demux: example Port #6428 Port #9157 Port #5775 application P3 transport network link physical application P1 transport network link physical application P4 transport network link physical source port: 6428 dest port: 9157 source port:? dest port:? source port: 9157 dest port: 6428 source port:? dest port:? Transport Layer 3-42

43 Connection-oriented demux TCP socket identified by 4-tuple: source IP address source port number dest IP address dest port number demux: receiver uses all four values to direct segment to appropriate socket server host may support many simultaneous TCP sockets: each socket identified by its own 4-tuple web servers have different sockets for each connecting client non-persistent HTTP will have different socket for each request Transport Layer 3-43

44 Connection-oriented demux: example threaded server application application P3 transport network link physical P4 transport network link physical server: IP address B application P2 P3 transport network link physical host: IP address A source IP,port: B,80 dest IP,port: A,9157 source IP,port: C,5775 dest IP,port: B,80 host: IP address C source IP,port: A,9157 dest IP, port: B,80 three segments, all destined to IP address: B, dest port: 80 are demultiplexed to different sockets source IP,port: C,9157 dest IP,port: B,80 Transport Layer 3-44

45 Chapter 3 outline 3.1 transport-layer services 3.2 multiplexing and demultiplexing 3.3 connectionless transport: UDP 3.4 principles of reliable data transfer 3.5 connection-oriented transport: TCP segment structure reliable data transfer flow control connection management 3.6 principles of congestion control 3.7 TCP congestion control Transport Layer 3-45

46 UDP: User Datagram Protocol [RFC 768] no frills, bare bones Internet transport protocol best effort service, UDP segments may be: lost delivered out-of-order to app connectionless: no handshaking between UDP sender, receiver each UDP segment handled independently of others UDP use: streaming multimedia apps (loss tolerant, rate sensitive) DNS SNMP reliable transfer over UDP: add reliability at application layer application-specific error recovery! Transport Layer 3-46

47 UDP: segment header 32 bits source port # dest port # length application data (payload) checksum UDP segment format length, in bytes of UDP segment, including header why is there a UDP? no connection establishment (which can add delay) simple: no connection state at sender, receiver small header size no congestion control: UDP can blast away as fast as desired Transport Layer 3-47

48 UDP checksum Goal: detect errors (e.g., flipped bits) in transmitted segment sender: treat segment contents, including header fields, as sequence of 16-bit integers checksum: addition (one s complement sum) of segment contents sender puts checksum value into UDP checksum field receiver: compute checksum of received segment check if computed checksum equals checksum field value: NO - error detected YES - no error detected. But maybe errors nonetheless? More later. Transport Layer 3-48

49 Internet checksum: example example: add two 16-bit integers wraparound sum checksum Note: when adding numbers, a carryout from the most significant bit needs to be added to the result Transport Layer 3-49

50 Example P3: UDP and TCP use 1s complement for their checksums. Suppose you have the following three 8-bit bytes: , , What is the 1s complement of the sum of these 8-bit bytes? With the 1s complement scheme, how does the receiver detect errors? Is it possible that a 1-bit error will go undetected? How about a 2-bit error? Transport Layer 3-50

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 6

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 6 CMPE 150/L : Introduction to Computer Networks Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 6 1 Midterm room for overflow students The students who used my registration code to enroll

More information

Chapter 3 Transport Layer

Chapter 3 Transport Layer Chapter 3 Transport Layer Lec 8: Transport Layer Service Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 All material copyright 1996-2012 J.F Kurose

More information

Chapter II: Application Layer

Chapter II: Application Layer Chapter II: Application Layer UG3 Computer Communications & Networks (COMN) Myungjin Lee myungjin.lee@ed.ac.uk Slides copyright of Kurose and Ross Internet hourglass Here 2 Some network apps e-mail web

More information

Computer Communication Networks Socket Programming

Computer Communication Networks Socket Programming Computer Communication Networks Socket Programming ICEN/ICSI 416 Fall 2018 Prof. Aveek Dutta 1 Application Programming Interface Interface exported by the network Since most network protocols are implemented

More information

Chapter 3 Transport Layer

Chapter 3 Transport Layer Chapter 3 Transport Layer A note on the use of these Powerpoint slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Chapter 2: outline. 2.1 principles of network applications. 2.6 P2P applications 2.7 socket programming with UDP and TCP

Chapter 2: outline. 2.1 principles of network applications. 2.6 P2P applications 2.7 socket programming with UDP and TCP Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming

More information

CSC 401 Data and Computer Communications Networks

CSC 401 Data and Computer Communications Networks CSC 401 Data and Computer Communications Networks Transport Layer Intro, Mutliplexing/Demultiplexing, UDP Sec 3.1 3.4 Prof. Lina Battestilli Fall 2017 Chapter 3: Transport Layer our goals: understand principles

More information

CS 4390 Computer Networks. Transport Services and Protocols

CS 4390 Computer Networks. Transport Services and Protocols CS 4390 Computer Networks UT D data Session 07 Transport Layer Overview and UDP Adapted from Computer Networking a Top-Down Approach 1996-2012 by J.F Kurose and K.W. Ross, All Rights Reserved Transport

More information

We will cover in this order: 2.1, 2.7, 2.5, 2.4, 2.2

We will cover in this order: 2.1, 2.7, 2.5, 2.4, 2.2 CSE 422 Notes, Set 2 These slides contain materials provided with the text: Computer Networking: A Top Down Approach,5 th edition, by Jim Kurose and Keith Ross, Addison-Wesley, April 2009. Additional figures

More information

Transport Layer. Chapter 3: Transport Layer

Transport Layer. Chapter 3: Transport Layer Transport Layer EECS 3214 Slides courtesy of J.F Kurose and K.W. Ross, All Rights Reserved 29-Jan-18 1-1 Chapter 3: Transport Layer our goals: understand principles behind layer services: multiplexing,

More information

Chapter 2: outline. 2.1 principles of network applications app architectures app requirements

Chapter 2: outline. 2.1 principles of network applications app architectures app requirements Chapter 2: outline 2.1 principles of network applications app architectures app requirements 2.2 Web and HTTP 2.3 FTP 2.4 electronic mail SMTP, POP3, IMAP 2.5 DNS 2.6 P2P applications 2.7 socket programming

More information

Web Caching and HTTPS

Web Caching and HTTPS Web Caching and HTTPS Caching as a technique to reduce user (perceived) response time Who caches? Origin server (database memory) Gateway reverse proxy (shared cache) Proxy (e.g., ISP share cache) Browser

More information

Distributed Systems. Networking Slides courtesy Kurose & Ross

Distributed Systems. Networking Slides courtesy Kurose & Ross Distributed Systems Networking Slides courtesy Kurose & Ross Agenda Computer networks, primarily from an application perspective Protocol layering Client-server architecture End-to-end principle TCP Socket

More information

CSC 4900 Computer Networks: Transport Layer

CSC 4900 Computer Networks: Transport Layer CSC 4900 Computer Networks: Transport Layer Professor Henry Carter Fall 2017 Last Time... Sockets programming API TCP and UDP look different. Remember, there is no connect() in UDP - just start sending

More information

CSEN 503 Introduction to Communication Networks. Mervat AbuElkheir Hana Medhat Ayman Dayf. ** Slides are attributed to J. F.

CSEN 503 Introduction to Communication Networks. Mervat AbuElkheir Hana Medhat Ayman Dayf. ** Slides are attributed to J. F. CSEN 503 Introduction to Communication Networks Mervat AbuElkheir Hana Medhat Ayman Dayf ** Slides are attributed to J. F. Kurose Chapter 3 outline Transport-layer services Multiplexing and demultiplexing

More information

Application Programming Interfaces

Application Programming Interfaces Application Programming Interfaces The TCP/IP protocol suite provides only the protocols that can be used by processes to communicate across a network. Though standarized, how these protocols are implemented

More information

CMSC 332 Computer Networks Transport Layer

CMSC 332 Computer Networks Transport Layer CMSC 332 Computer Networks Transport Layer Professor Szajda Announcements Project I - I ll test against various clients (still possibly an issue in spec). Project 2 will be posted soon (but first, I want

More information

Chapter III: Transport Layer

Chapter III: Transport Layer Chapter III: Transport Layer UG3 Computer Communications & Networks (COMN) Mahesh Marina mahesh@ed.ac.uk Slides thanks to Myungjin Lee and copyright of Kurose and Ross Transport services and protocols

More information

CS 3516: Computer Networks

CS 3516: Computer Networks Welcome to CS 3516: Computer Networks Prof. Yanhua Li Time: 9:00am 9:50am, T, R, and F Location: AK219 Fall 2018 A-term 1 Some slides are originally from the course materials of the textbook Computer Networking:

More information

CC451 Computer Networks

CC451 Computer Networks CC451 Computer Networks Lecture 4 Application Layer (cont d) Application Layer 1 Chapter 2: Application layer 2.1 Principles of network applications 2.2 Web and HTTP 2.3 FTP 2.4 Electronic Mail SMTP, POP3,

More information

Lecture 9: Transpor Layer Overview and UDP

Lecture 9: Transpor Layer Overview and UDP Lecture 9: Transpor Layer Overview and UDP COMP 332, Spring 2018 Victoria Manfredi Acknowledgements: materials adapted from Computer Networking: A Top Down Approach 7 th edition: 1996-2016, J.F Kurose

More information

FTP. Mail. File Transfer Protocol (FTP) FTP commands, responses. Electronic Mail. TDTS06: Computer Networks

FTP. Mail. File Transfer Protocol (FTP) FTP commands, responses. Electronic Mail. TDTS06: Computer Networks TDTS0: Computer Networks Instructor: Niklas Carlsson Email: niklas.carlsson@liu.se FTP Notes derived from Computer Networking: A Top Down Approach, by Jim Kurose and Keith Ross, Addison-Wesley. The slides

More information

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 7

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 7 CMPE 150/L : Introduction to Computer Networks Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 7 1 Lab2 and Homework questions Available on course website 2 Chapter 3 outline 3.1 transport-layer

More information

Application Layer. CMPS 4750/6750: Computer Networks

Application Layer. CMPS 4750/6750: Computer Networks Application Layer CMPS 4750/6750: Computer Networks 1 Agenda Principles of Network Applications Case Studies Web and HTTP Email Domain Name System (DNS) Peer-to-Peer File Sharing Socket Programming with

More information

Suprakash Datta. Office: CSEB 3043 Phone: ext Course page:

Suprakash Datta. Office: CSEB 3043 Phone: ext Course page: CSE 3214: Computer Networks Protocols and Applications Suprakash Datta datta@cse.yorku.ca Office: CSEB 3043 Phone: 416-736-2100 ext 77875 Course page: http://www.cse.yorku.ca/course/3214 These slides are

More information

Section 2: Application layer

Section 2: Application layer Section 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 applications 2.7 Socket programming with UDP 2.8 Socket

More information

Distributed Systems. Remote Procedure Calls

Distributed Systems. Remote Procedure Calls Distributed Systems Remote Procedure Calls Today s Agenda Last time: Computer networks, primarily from an application perspective Protocol layering Client-server architecture End-to-end principle Today:

More information

Client/Server Computing & Socket Programming

Client/Server Computing & Socket Programming COMP 431 Internet Services & Protocols Client/Server Computing & Socket Programming Jasleen Kaur January 29, 2019 Application-Layer Protocols Overview Application-layer protocols define:» The types of

More information

Lecture 05: Application Layer (Part 02) Domain Name System. Dr. Anis Koubaa

Lecture 05: Application Layer (Part 02) Domain Name System. Dr. Anis Koubaa NET 331 Computer Networks Lecture 05: Application Layer (Part 02) Domain Name System Dr. Anis Koubaa Reformatted slides from textbook Computer Networking a top-down appraoch, Fifth Edition by Kurose and

More information

Computer Networking Introduction

Computer Networking Introduction Computer Networking Introduction Halgurd S. Maghdid Software Engineering Department Koya University-Koya, Kurdistan-Iraq Lecture No.6 Chapter 2: outline 2.1 principles of network applications app architectures

More information

Chapter 2 outline. 2.1 Principles of app layer protocols

Chapter 2 outline. 2.1 Principles of app layer protocols Chapter 2 outline 2.1 Principles of app layer protocols clients and servers app requirements 2.2 Web and HTTP 2.3 FTP 2.4 Electronic Mail SMTP, POP3, IMAP 2.5 DNS 2.6 Socket programming with TCP 2.7 Socket

More information

CSC358 Week 4. Adapted from slides by J.F. Kurose and K. W. Ross. All material copyright J.F Kurose and K.W. Ross, All Rights Reserved

CSC358 Week 4. Adapted from slides by J.F. Kurose and K. W. Ross. All material copyright J.F Kurose and K.W. Ross, All Rights Reserved CSC358 Week 4 Adapted from slides by J.F. Kurose and K. W. Ross. All material copyright 1996-2016 J.F Kurose and K.W. Ross, All Rights Reserved Logistics Assignment 1 due this Friday Office hour on Feb

More information

Chapter 3: Transport Layer. Chapter 3 Transport Layer. Chapter 3 outline. Transport services and protocols

Chapter 3: Transport Layer. Chapter 3 Transport Layer. Chapter 3 outline. Transport services and protocols Chapter 3 Transport Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you can add, modify, and delete

More information

CSCE 463/612 Networks and Distributed Processing Spring 2018

CSCE 463/612 Networks and Distributed Processing Spring 2018 CSCE 463/612 Networks and Distributed Processing Spring 2018 Transport Layer Dmitri Loguinov Texas A&M University February 22, 2018 Original slides copyright 1996-2004 J.F Kurose and K.W. Ross 1 Chapter

More information

Chapter 2 Application Layer. Lecture 5 DNS. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

Chapter 2 Application Layer. Lecture 5 DNS. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 Chapter 2 Application Layer Lecture 5 DNS Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 Application Layer 2-1 Chapter 2: outline 2.1 principles

More information

Chapter 3 Transport Layer

Chapter 3 Transport Layer Chapter 3 Transport Layer All material copyright 1996-2016 J.F Kurose and K.W. Ross, All Rights Reserved Computer Networking: A Top Down Approach 7 th edition Jim Kurose, Keith Ross Pearson/Addison Wesley

More information

COSC4377. Useful Linux Tool: screen

COSC4377. Useful Linux Tool: screen Lecture 10 Useful Linux Tool: screen Alternative to having multiple ssh/putty screens, you can have multiple virtual screens within the same session. To open a screen session: ~$ screen To suspend the

More information

Chapter 2: outline. 2.5 P2P applications 2.6 video streaming and content distribution networks 2.7 socket programming with UDP and TCP

Chapter 2: outline. 2.5 P2P applications 2.6 video streaming and content distribution networks 2.7 socket programming with UDP and TCP Chapter 2: outline 2.1 principles of network applications 2.2 Web and HTTP 2.3 electronic mail SMTP, POP3, IMAP 2.4 DNS 2.5 P2P applications 2.6 video streaming and content distribution networks 2.7 socket

More information

Development of reliable protocol Sliding window protocols. C = channel capacity in bps I = interrupt/service time + propagation delay

Development of reliable protocol Sliding window protocols. C = channel capacity in bps I = interrupt/service time + propagation delay Outline Development of reliable protocol Sliding window protocols Go-Back-N, Selective Repeat Protocol performance Sockets, UDP, TCP, and IP UDP operation TCP operation connection management flow control

More information

The Application Layer: Sockets, DNS

The Application Layer: Sockets, DNS The Application Layer: Sockets, DNS CS 352, Lecture 3 http://www.cs.rutgers.edu/~sn624/352-s19 Srinivas Narayana 1 App-layer protocol Types of messages exchanged, e.g., request, response Message format:

More information

The Application Layer: Sockets Wrap-Up

The Application Layer: Sockets Wrap-Up The Application Layer: Sockets Wrap-Up CSC 249 February 8, 2018 slides mostly from J.F Kurose and K.W. Ross,copyright 1996-2012 1 Socket Overview q Examples with socket-api programming q Differences between

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

CSE 4213: Computer Networks II

CSE 4213: Computer Networks II Next CSE 4213: Computer Networks II The layer Suprakash Datta datta@cs.yorku.ca Office: CSEB 3043 Phone: 416-736-2100 ext 77875 Course page: http://www.cs.yorku.ca/course/4213 These slides are adapted

More information

Application Layer: P2P File Distribution

Application Layer: P2P File Distribution Application Layer: P2P File Distribution EECS 3214 Slides courtesy of J.F Kurose and K.W. Ross, All Rights Reserved 29-Jan-18 1-1 Chapter 2: outline 2.1 principles of network applications 2.2 Web and HTTP

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Chapter 2: outline. 2.5 P2P applications 2.6 video streaming and content distribution networks 2.7 socket programming with UDP and TCP

Chapter 2: outline. 2.5 P2P applications 2.6 video streaming and content distribution networks 2.7 socket programming with UDP and TCP Chapter 2: outline 2.1 principles of network applications 2.2 Web and HTTP 2.3 electronic mail SMTP, POP3, IMAP 2.4 DNS 2.5 P2P applications 2.6 video streaming and content distribution networks 2.7 socket

More information

Application. Transport. Network. Link. Physical

Application. Transport. Network. Link. Physical Transport Layer ELEC1200 Principles behind transport layer services Multiplexing and demultiplexing UDP TCP Reliable Data Transfer TCP Congestion Control TCP Fairness *The slides are adapted from ppt slides

More information

Chapter 1 Introduction

Chapter 1 Introduction Chapter 1 Introduction Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 Slides adopted from original ones provided by the textbook authors. Introduction

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Input ports, switching fabric, output ports Switching via memory, bus, crossbar Queueing, head-of-line blocking

Input ports, switching fabric, output ports Switching via memory, bus, crossbar Queueing, head-of-line blocking Last time Router internals Input ports, switching fabric, output ports Switching via memory, bus, crossbar Queueing, head-of-line blocking Mobility Home, visited s Home, foreign agents Permanent, care-of

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you can add, modify, and

More information

CMPE 80N: Introduction to Networking and the Internet

CMPE 80N: Introduction to Networking and the Internet CMPE 80N: Introduction to Networking and the Internet Katia Obraczka Computer Engineering UCSC Baskin Engineering Lecture 11 CMPE 80N Fall'10 1 Announcements Forum #2 due on 11.05. CMPE 80N Fall'10 2 Last

More information

CSCD 330 Network Programming

CSCD 330 Network Programming CSCD 330 Network Programming Lecture 9 Transport Layer Winter 2019 Reading: Begin Chapter 3 Some Material in these slides from J.F Kurose and K.W. Ross All material copyright 1996-2007 1 Outline Overview

More information

Announcement. Homework 1 due last night, how is that? Will discuss some problems in the lecture next week

Announcement. Homework 1 due last night, how is that? Will discuss some problems in the lecture next week Announcement Homework 1 due last night, how is that? Will discuss some problems in the lecture next week Should have completed at least part II of project 1 Homework 2 will be out next week Review of Previous

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Chapter 2: outline. 2.6 P2P applications 2.7 socket programming with UDP and TCP

Chapter 2: outline. 2.6 P2P applications 2.7 socket programming with UDP and TCP Chapter 2: outline 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 applications 2.7 socket programming with UDP and TCP Application

More information

Application Layer Protocols

Application Layer Protocols Application Layer Protocols Dr. Ihsan Ullah Department of Computer Science & IT University of Balochistan, Quetta Pakistan Email: ihsan.ullah.cs@gmail.com These slides are adapted from the slides accompanying

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you can add, modify, and

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer Lu Su Assistant Professor Department of Computer Science and Engineering State University of New York at Buffalo Adapted from the slides of the book s authors Computer Networking:

More information

Introduction to the Transport Layer

Introduction to the Transport Layer Introduction to the Transport Layer CSC 249 Feb 13, 2018 1 Transport Layer Overview q Tasks performed by the layer v Services provided to the layer v Services expected from the layer q Multiplexing and

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer Chapter 2: outline 2.1 principles of network applications 2.2 Web and HTTP 2.3 electronic mail SMTP, POP3, IMAP 2.4 DNS 2.5 P2P applications 2.6 video streaming and content

More information

Chapter 2: Application layer

Chapter 2: Application layer 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 applications 2.7 Socket programming with TCP 2.8 Socket

More information

Domain Name System (DNS) 김현철 ( 화 ) 정보통신융합서울대학교컴퓨터공학부

Domain Name System (DNS) 김현철 ( 화 ) 정보통신융합서울대학교컴퓨터공학부 Domain Name System (DNS) 김현철 2010.09.29 ( 화 ) 정보통신융합서울대학교컴퓨터공학부 Chapter 2 Application Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students,

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer Andrei Gurtov Computer Networking: A Top Down Approach All material copyright 1996-2016 J.F Kurose and K.W. Ross, All Rights Reserved 7 th edition Jim Kurose, Keith Ross Pearson/Addison

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these Powerpoint slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Chapter 6 Transport Layer

Chapter 6 Transport Layer Chapter 6 Transport Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you can add, modify, and delete

More information

Application Layer. Chapter 2. Computer Networking: A Top Down Approach. A note on the use of these Powerpoint slides:

Application Layer. Chapter 2. Computer Networking: A Top Down Approach. A note on the use of these Powerpoint slides: Chapter 2 Application Layer A note on the use of these Powerpoint slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Chapter 2 Application Layer A note on the use of these Powerpoint slides: We re making these slides freely available to all (faculty, students, readers). They re in PowerPoint form so you see the animations;

More information

EC441 Fall 2018 Introduction to Computer Networking Chapter 2: Application Layer

EC441 Fall 2018 Introduction to Computer Networking Chapter 2: Application Layer EC441 Fall 2018 Introduction to Computer Networking Chapter 2: Application Layer This presentation is adapted from slides produced by Jim Kurose and Keith Ross for their book, Computer Networking: A Top

More information

CSC 4900 Computer Networks: P2P and Sockets

CSC 4900 Computer Networks: P2P and Sockets CSC 4900 Computer Networks: P2P and Sockets Professor Henry Carter Fall 2017 Recap SMTP is the language that mail servers use to exchange messages. SMTP is push-based... why? You can run SMTP from a telnet

More information

Chapter 3 Transport Layer

Chapter 3 Transport Layer Chapter 3 Transport Layer Reti degli Elaboratori Canale AL e MZ Prof.ssa Chiara Petrioli a.a. 2016/2017 We thank for the support material Prof. Kurose-Ross All material copyright 1996-2012 J.F Kurose and

More information

CSC 401 Data and Computer Communications Networks

CSC 401 Data and Computer Communications Networks CSC 401 Data and Computer Communications Networks Application Layer Video Streaming, CDN and Sockets Sec 2.6 2.7 Prof. Lina Battestilli Fall 2017 Outline Application Layer (ch 2) 2.1 principles of network

More information

Chapter 3: Transport Layer Part A

Chapter 3: Transport Layer Part A Chapter 3: Transport Layer Part A Course on Computer Communication and Networks, CTH/GU The slides are adaptation of the slides made available by the authors of the course s main textbook 3: Transport

More information

Transport Layer Overview

Transport Layer Overview Transport Layer Overview Kai Shen Transport-layer Overview Network layer: host-to-host to logical communication between hosts. Transport layer: logical communication between s. multiple comm. s can reside

More information

Transport layer. Our goals: Understand principles behind transport layer services: Learn about transport layer protocols in the Internet:

Transport layer. Our goals: Understand principles behind transport layer services: Learn about transport layer protocols in the Internet: Transport layer Our goals: Understand principles behind transport layer services: Multiplexing/demultiplexing Reliable data transfer Flow control Congestion control Learn about transport layer protocols

More information

Transport layer: Outline

Transport layer: Outline Transport layer Our goals: Understand principles behind transport layer services: Multiplexing/demultiplexing Reliable data transfer Flow control Congestion control Learn about transport layer protocols

More information

Application Layer: , DNS

Application Layer:  , DNS Application Layer: E-mail, DNS EECS 3214 Slides courtesy of J.F Kurose and K.W. Ross, All Rights Reserved 22-Jan-18 1-1 Chapter 2: outline 2.1 principles of network applications 2.2 Web and HTTP 2.3 electronic

More information

CSE 3214: Computer Network Protocols and Applications Transport Layer (Part 2) Chapter 3 outline. UDP checksum. Port numbers

CSE 3214: Computer Network Protocols and Applications Transport Layer (Part 2) Chapter 3 outline. UDP checksum. Port numbers CSE 3214: Computer Network Protocols and Applications Transport Layer (Part 2) Dr. Peter Lian, Professor Department of Computer Science and Engineering York University Email: peterlian@cse.yorku.ca Office:

More information

Computer Networking Introduction

Computer Networking Introduction Computer Networking Introduction Halgurd S. Maghdid Software Engineering Department Koya University-Koya, Kurdistan-Iraq Lecture No.5 Chapter 2: outline 2.1 principles of network applications app architectures

More information

Chapter 2 Application Layer

Chapter 2 Application Layer Internet and Intranet Protocols and Applications Lecture 4: Application Layer 3: Socket Programming Spring 2006 Arthur Goldberg Computer Science Department New York University artg@cs.nyu.edu Chapter 2

More information

CSC 401 Data and Computer Communications Networks

CSC 401 Data and Computer Communications Networks CSC 401 Data and Computer Communications Networks Application Layer DNS and P2P Sec 2.4 2.5 Prof. Lina Battestilli Fall 2017 Outline Application Layer (ch 2) 2.1 principles of network applications 2.2

More information

Web caches (proxy server)

Web caches (proxy server) Web caches (proxy server) goal: satisfy client request without involving origin server user sets browser: Web accesses via cache browser sends all HTTP requests to cache object in cache: cache returns

More information

Computer Networks COMPUTER NETWORKS

Computer Networks COMPUTER NETWORKS SEMESTER V COMPUTER NETWORKS Subject Code IA Marks 20 Number of Lecture Hours/Week 4 Exam Marks 80 Total Number of Lecture Hours 50 Exam Hours 03 CREDITS 04 Course objectives: This course will enable students

More information

CC451 Computer Networks

CC451 Computer Networks CC451 Computer Networks Lecture 5 Transport Layer Transport Layer 3-1 Chapter 3 Transport Layer A note on the use of these ppt slides: We re making these slides freely available to all (faculty, students,

More information

ELEC / COMP 177 Fall Some slides from Kurose and Ross, Computer Networking, 5 th Edition

ELEC / COMP 177 Fall Some slides from Kurose and Ross, Computer Networking, 5 th Edition ELEC / COMP 177 Fall 2013 Some slides from Kurose and Ross, Computer Networking, 5 th Edition Project 1 Python HTTP Server Work day: Next Tuesday (Sept 24 th ) Due Thursday, September 26 th by 11:55pm

More information

Communication in Distributed Systems: Sockets Programming. Operating Systems

Communication in Distributed Systems: Sockets Programming. Operating Systems Communication in Distributed Systems: Sockets Programming Operating Systems TCP/IP layers Layers Message Application Transport Internet Network interface Messages (UDP) or Streams (TCP) UDP or TCP packets

More information

Chapter 3 Transport Layer

Chapter 3 Transport Layer Chapter 3 Transport Layer These slides are adapted from the original slides provided by J.Kurose and K.W Ross. All material copyright 1996-2012 J.F Kurose and K.W. Ross, All Rights Reserved Computer Networking:

More information

Internet and Intranet Protocols and Applications

Internet and Intranet Protocols and Applications Internet and Intranet Protocols and Applications Lecture 1b: The Transport Layer in the Internet January 17, 2006 Arthur Goldberg Computer Science Department New York University artg@cs.nyu.edu 01/17/06

More information

Introduction to Computer Networking. Guy Leduc. Chapter 2 Application Layer. Chapter 2: outline

Introduction to Computer Networking. Guy Leduc. Chapter 2 Application Layer. Chapter 2: outline Introduction to Computer Networking Guy Leduc Chapter 2 Application Layer Computer Networking: A Top Down Approach, 7 th edition. Jim Kurose, Keith Ross Addison-Wesley, April 2016 2: Application Layer

More information

TDTS06: Computer Networks

TDTS06: Computer Networks TDTS06: Computer Networks Instructor: Niklas Carlsson Email: niklas.carlsson@liu.se Notes derived from Computer Networking: A Top Down Approach, by Jim Kurose and Keith Ross, Addison-Wesley. The slides

More information

Computer Communication Networks Midterm Review

Computer Communication Networks Midterm Review Computer Communication Networks Midterm Review ICEN/ICSI 416 Fall 2017 Prof. Dola Saha 1 Instructions Put your name and student id on each sheet of paper! The exam is closed book. You cannot use any computer

More information

CSCE 463/612 Networks and Distributed Processing Spring 2018

CSCE 463/612 Networks and Distributed Processing Spring 2018 CSCE 463/612 Networks and Distributed Processing Spring 2018 Application Layer III Dmitri Loguinov Texas A&M University February 8, 2018 Original slides copyright 1996-2004 J.F Kurose and K.W. Ross 1 Chapter

More information

Chapter 3: Transport Layer

Chapter 3: Transport Layer Chapter 3: Transport Layer Chapter goals: understand principles behind transport layer services: multiplexing/demultiplex ing reliable data transfer flow control congestion control instantiation and implementation

More information

Domain Name Service. DNS Overview. October 2009 Computer Networking 1

Domain Name Service. DNS Overview. October 2009 Computer Networking 1 Domain Name Service DNS Overview October 2009 Computer Networking 1 Why DNS? Addresses are used to locate objects (contain routing information) Names are easier to remember and use than numbers DNS provides

More information

Esempi di programmi client/server in Python 2

Esempi di programmi client/server in Python 2 Reti di Calcolatori I Prof. Roberto Canonico Dipartimento di Ingegneria Elettrica e delle Tecnologie dell Informazione Corso di Laurea in Ingegneria Informatica A.A. 2018-2019 Esempi di programmi client/server

More information

Lecture 2 Communication services The Trasport Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Lecture 2 Communication services The Trasport Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it Lecture 2 Communication services The Trasport Layer Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it The structure edge: applications and hosts core: routers of s access s, media:

More information

Chapter 2: Application layer

Chapter 2: Application layer Chapter 2: Application layer 2. 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 applications 2.7 Socket programming

More information

Chapter 2 part B: outline

Chapter 2 part B: outline Chapter 2 part B: outline 2.3 FTP 2.4 electronic, POP3, IMAP 2.5 DNS Application Layer 2-1 FTP: the file transfer protocol at host FTP interface FTP client local file system file transfer FTP remote file

More information

Transport services and protocols. Chapter 3 outline. Internet transport-layer protocols Chapter 3 outline. Multiplexing/demultiplexing

Transport services and protocols. Chapter 3 outline. Internet transport-layer protocols Chapter 3 outline. Multiplexing/demultiplexing Chapter 3 outline 3.1 Transport-layer services 3.2 Multiplexing and demultiplexing 3.3 Connectionless : UDP 3.4 Principles of reliable data transfer 3.5 Connection-oriented : TCP segment structure reliable

More information