HTTP and DNS
HTTP and DNS
Application Layer
time
6. Steps 1-5 repeated for each of 10
jpeg objects
~
~ entity body ~
~ body
URL method:
uses GET method
input is uploaded in URL
field of request line:
www.somesite.com/animalsearch?monkeys&banana
200 OK
• request succeeded, requested object later in this msg
301 Moved Permanently
• requested object moved, new location specified later in this msg
(Location:)
400 Bad Request
• request msg not understood by server
404 Not Found
• requested document not found on this server
505 HTTP Version Not Supported
Application Layer 2-16
Trying out HTTP (client side) for yourself
1. Telnet to your favorite Web server:
telnet gaia.cs.umass.edu 80 opens TCP connection to port 80
(default HTTP server port)
at gaia.cs.umass. edu.
anything typed in will be sent
to port 80 at gaia.cs.umass.edu
ebay 8734
usual http request msg Amazon server
cookie file creates ID
usual http response
1678 for user create backend
ebay 8734
set-cookie: 1678 entry database
amazon 1678
usual http request msg
cookie: 1678 cookie- access
specific
usual http response msg action
… …
m. WIDE Tokyo
e. NASA Mt View, CA (5 other sites)
f. Internet Software C.
Palo Alto, CA (and 48 other sites)
gaia.cs.umass.edu
type=A type=CNAME
name is hostname name is alias name for some
value is IP address “ canonical” (the real) name
www.ibm.com is really
type=NS
• name is domain (e.g., servereast.backup2.ibm.com
foo.com) value is canonical name
• value is hostname of
authoritative name type=MX
server for this domain value is name of mailserver
associated with name
2 bytes 2 bytes
identification flags