![Page 1: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/1.jpg)
SMU CSE 4344
application layer
![Page 2: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/2.jpg)
SMU CSE 4344
application vs. application-layer protocols
• application-layer protocol is just one piece– how the end hosts communicate
• example: World Wide Web– HyperText Transfer Protocol (HTTP) is protocol– but the Web includes other components, such as
document formats (HTML), Web browsers, servers, …
• example: electronic mail– Simple Mail Transfer Protocol (SMTP) is protocol– but e-mail includes other components, such as mail
servers, user mailboxes, mail readers
![Page 3: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/3.jpg)
SMU CSE 4344
DNS – Domain Name System
• DNS maps ASCII host names (e.g., marge.engr.smu.edu) & email addresses (e.g., [email protected]) to IP addresses
• resolver procedure queries DNS name server with ASCII name parameter, gets back resource record
• numeric IP addresses used for Internet routing• domains are hierarchical
![Page 4: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/4.jpg)
SMU CSE 4344
zones
• DNS name space comprises zones
• each zone has its own name server(s)
• authoritative record vs. cached record
![Page 5: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/5.jpg)
SMU CSE 4344
DNS zones
Part of the DNS name space showing the division into zones.
![Page 6: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/6.jpg)
SMU CSE 4344
DNS lookup illustration
• a resolver looks up host linda.cs.yale.edu• recursive query
![Page 7: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/7.jpg)
SMU CSE 4344
email: architecture and services• user agent• mail transfer agent (daemon)• basic application functions
– composition• addresses, other header fields, text body
– transfer (MX to MX)– reporting (bounced, delivered, still trying)– displaying (folders, messages)
• status: unread, read, answered, deleted• text, attachments
– disposition (delete, save, organize, recycle)
![Page 8: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/8.jpg)
SMU CSE 4344
email message format – RFC 822
RFC 822 header fields related to message transport
![Page 9: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/9.jpg)
SMU CSE 4344
RFC 822
more RFC 822 message header fields
![Page 10: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/10.jpg)
SMU CSE 4344
MIME headers
MIME defines encoding rules for non-ASCII, using five additional RFC 822-compliant headers
![Page 11: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/11.jpg)
SMU CSE 4344
message transfer
• SMTP: Simple Mail Transfer Protocol– TCP over well-
known port 25– ASCII protocol
![Page 12: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/12.jpg)
SMU CSE 4344
final delivery
-Post Office Protocol v. 3 (POP3): client downloads messages (port 110)
- Internet Message Access Protocol (IMAP): msgs stay on server (port 143)
![Page 13: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/13.jpg)
SMU CSE 4344
POP3 vs. IMAP
![Page 14: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/14.jpg)
SMU CSE 4344
World Wide Web (WWW)
• architectural overview• HTTP – HyperText Transfer Protocol• performance enhancements
![Page 15: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/15.jpg)
SMU CSE 4344
WWW origins
• hypertext, Vannevar Bush, M.I.T., 1945• Tim Berners-Lee, CERN, 1989
– proposal: networked “web” of hyperlinked documents
• Marc Andreessen, U Illinois– Mosaic graphical browser, 1993– Netscape, 1994
• World Wide Web Consortium (W3C)– CERN, M.I.T.– standardization effort– director, Tim Berners-Lee
![Page 16: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/16.jpg)
SMU CSE 4344
WWW architecture
• web pages and hyperlinks• web servers host web pages• client software: web browser• basic operation
– user selects a hyperlink– browser requests IP address from DNS– browser requests hyperlink-identified web page – web server sends new web page– browser “renders” new web page– only whole pages sent
![Page 17: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/17.jpg)
SMU CSE 4344
architectural overview
![Page 18: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/18.jpg)
SMU CSE 4344
WWW clients
• URL: Uniform Resource Locator• hyperlinks are based on URLs
– <protocol>://<DNSname>/<filename>– http://engr.smu.edu/~donm/4344.html
• WWW services at well-known port 80• HyperText Markup Language: HTML
![Page 19: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/19.jpg)
SMU CSE 4344
URLs – Uniform Resource Locaters
Some common URLs.
![Page 20: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/20.jpg)
SMU CSE 4344
display of non-HTML content
• plug-ins extend the browsers capabilities• helpers are independent processes• dynamic content: PHP, JSP, ASP, perl, javascript• Wireless Application Protocol (WAP); i-mode; ...
![Page 21: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/21.jpg)
SMU CSE 4344
web servers
multi-threaded Web server with front end and processing modules
![Page 22: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/22.jpg)
SMU CSE 4344
server farm
![Page 23: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/23.jpg)
SMU CSE 4344
caching
Hierarchical caching with three proxies.
![Page 24: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/24.jpg)
SMU CSE 4344
caching vs. replication
• motivations for moving content close to users– reduce latency for user– reduce load on network and server
• caching– replicating content “on demand” after request– storing response message locally for future use
• replication– planned replication of content in multiple locations– updating of resources is handled outside of HTTP– can replicate scripts that create dynamic responses
![Page 25: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/25.jpg)
SMU CSE 4344
caching vs. replication• caching first seen as very important in HTTP
– many additions to HTTP to support caching• in particular, cache validation
• deployment of caching proxies in the 1990s– service providers & enterprises deployed proxies– … to cache content across a community of users– sometimes, gains were not very dramatic
• then, content distribution networks emerged– companies (like Akamai) that replicate Web sites– host all (or part) of a Web site for a content provider– place replicas all over world on many machines
![Page 26: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/26.jpg)
SMU CSE 4344
TCP interaction: multiple transfers• most Web pages have multiple objects
– e.g., HTML file, multiple embedded images
• serializing the transfers is not efficient– sending images one at a time introduces delay– cannot retrieve another image until first arrives
• parallel connections– browser opens multiple TCP connections … and
retrieves a single image on each connection
• performance trade-offs– multiple downloads share same network links– unfairness to other traffic traversing the links
![Page 27: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/27.jpg)
SMU CSE 4344
TCP interaction: short transfers
• HTTP transfers are short– very small request message
(e.g., a few hundred bytes)– small response message
(e.g., a few kilobytes)
• TCP overhead may be big– three-way handshake to
establish connection– four-way handshake to tear
down the connection
time to transmit file
initiate TCPconnection
RTT
requestfile
RTT
filereceived
time time
![Page 28: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/28.jpg)
SMU CSE 4344
TCP interaction: persistent connections
• handle multiple transfers per connection– added to HTTP after Web became very popular– maintain TCP connection across multiple requests– either client or server can tear down the connection
• performance advantages– avoid overhead of connection set-up and tear-down– allow TCP to learn a more accurate RTT estimate– allow the TCP congestion window to increase
• further enhancement: pipelining– send multiple requests one after the other … before
receiving the first response
![Page 29: SMUCSE 4344 application layer. SMUCSE 4344 application vs. application-layer protocols application-layer protocol is just one piece –how the end hosts](https://reader030.vdocuments.site/reader030/viewer/2022032710/56649e265503460f94b1552c/html5/thumbnails/29.jpg)
SMU CSE 4344
reflecting on application-layer protocols
• protocols are tailored to applications– each protocol is customized to a specific need
• protocols have many key similarities– each new protocol was influenced by the previous ones– new protocols commonly borrow from the older ones
• protocols depend on same underlying substrate– Domain Name System (DNS)– e.g., ordered reliable stream of bytes (i.e., TCP)
• relevance of the protocol standards process– important for interoperability across implementations– yet, not necessary if same party writes all of the software
• …which is increasingly common (e.g., P2P software)