












Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
An overview of the application layer in networking, focusing on its principles, popular protocols such as http, ftp, smtp, and dns, and application architectures like client-server and p2p. It also covers socket programming with tcp and udp.
Typology: Study notes
1 / 20
This page cannot be seen from the preview
Don't miss anything!













(modified by Cheung for EE586;
based on K&R original)
1-
2: Application Layer
2: Application Layer
conceptual,implementationaspects of networkapplication protocols^
transport-layerservice models client-serverparadigm peer-to-peerparadigm
^
learn about protocolsby examining popularapplication-levelprotocols^
HTTP FTP SMTP / POP3 / IMAP DNS ^
programming networkapplications^
socket API
2: Application Layer
2.1 Principles ofnetwork applications ^
2.2 Web and HTTP ^
^
2.4 Electronic Mail^
SMTP, POP3, IMAP ^
^
2.6 P2P applications ^
2.7 Socket programmingwith TCP ^
2.8 Socket programmingwith UDP
2: Application Layer
2.1 Principles ofnetwork applications ^
2.2 Web and HTTP ^
^
2.4 Electronic Mail^
SMTP, POP3, IMAP ^
^
2.6 P2P applications ^
2.7 Socket programmingwith TCP ^
2.8 Socket programmingwith UDP ^
2.9 Building a Webserver
(modified by Cheung for EE586;
based on K&R original)
1-
(modified by Cheung for EE586;
based on K&R original)
1- 10
always-on server ^
arbitrary end systemsdirectly communicate ^
peers are intermittentlyconnected and change IPaddresses ^
Self-scalable -> costeffective ^
Difficult to maintain andsecure
peer-peer
2: Application Layer
^
voice-over-IP P2P application ^
centralized server: finding address of remoteparty: ^
client-client connection: direct (not throughserver)
Instant messaging
^
chatting between two users is P2P ^
centralized service: client presencedetection/location• user registers its IP address with central
server when it comes online
addresses of buddies
2: Application Layer
program running
within a host. ^
within same host, twoprocesses communicateusing
inter-process
communication
(defined
by OS). ^
processes in differenthosts communicate byexchanging
messages
^
processes in same hostcan also communicatewith shared memory
Client process:
process
that initiatescommunication Server process:
process
that waits to becontacted ^
Note: applications withP2P architectures haveclient processes &server processes
2: Application Layer
Sockets ^
process sends/receivesmessages to/from its socket ^
socket analogous to door^
sending process shovesmessage out door sending process relies ontransport infrastructureon other side of door whichbrings message to socketat receiving process
host orserver process^ socket TCP withbuffers,variables
host orserver process^ socket TCP withbuffers,variables
Internet
controlledby OS
controlled byapp developer
^
API: (1) choice of transport protocol; (2) ability to fixa few parameters
(lots more on this later)
2: Application Layer
Addressing processes^
does IP address of host on which processruns suffice foridentifying theprocess?^
No,
processes can berunning on same host
includes both
IP address
and
port
numbers
associated with
process on host. ^
Example port numbers:^
HTTP server: 80 Mail server: 25 ^
to send HTTP messageto gaia.cs.umass.edu webserver:^
IP address:
128.119.245.
^
Port number:
80
^
more shortly…
2: Application Layer
What transport service does an app need? Data loss ^ some apps (e.g., audio) cantolerate some loss ^ other apps (e.g., filetransfer, telnet) require100% reliable datatransfer Timing ^ some apps (e.g.,Internet telephony,interactive games)require low delay to be“effective”
Throughput ^
some apps (e.g.,multimedia) requireminimum amount ofthroughput to be“effective” ^
other apps (“elastic apps”)make use of whateverthroughput they get Security ^
Encryption, dataintegrity, …
2: Application Layer
Internet transport protocols services TCP service:
connection-oriented:
setup
required between client andserver processes
reliable transport
between
sending and receiving process
flow control:
sender won’t
overwhelm receiver
congestion control:
throttle
sender when networkoverloaded
does not provide:
timing,
minimum throughputguarantees, security
UDP service: ^
unreliable data transferbetween sending andreceiving process ^
does not provide:connection setup,reliability, flow control,congestion control, timing,throughput guarantee, orsecurity Q:
why bother?
Why is
there a UDP?
2: Application Layer
Application
remote terminal access
Web file transfer
streaming multimedia
Internet telephony
Applicationlayer protocol SMTP [RFC 2821]Telnet [RFC 854]HTTP [RFC 2616]FTP [RFC 959]HTTP (eg Youtube),RTP [RFC 1889]SIP, RTP, proprietary(e.g., Skype)
Underlyingtransport protocol TCPTCPTCPTCPTCP or UDPtypically UDP