代写 html python socket network CSE3300: Computer Networking

CSE3300: Computer Networking
Homework 3
Due Date: October 4, 2019. Submission through HuskyCT.
1. DNS and HTTP (10 points). Suppose within your web browser you click on a link to obtain a web page. The IP address of the associated URL is not cached in your local host, so a DNS look-up is necessary to obtain the IP address. Suppose that n DNS servers are visited before your host eventually receives the IP address from DNS; the successive visits incur an RTT of RT T1, RT T2, . . . RT Tn. Further suppose that the web page associated with the link contains exactly one object, consisting of a small amount of HTML text (i.e., the URL only has a base HTML file, with no embedded objects). Let RTT0 denote the RTT between the local host and the server containing the object. Assuming zero transmission time of the object, how much time elapses from when the client clicks on the link until the client receives the object?
2. DNS (30 points). In this problem, we use the useful dig tool avail- able on Unix and Linux hosts to explore the hierarchy of DNS servers. Recall that DNS has a hierarchical architecture Ð a DNS server higher in the DNS hierarchy delegates a DNS query to a DNS server lower in the hierarchy, by sending back to the DNS client the name of that lower-level DNS server. First read the man page for dig, and then answer the following questions.
a. Starting with a root DNS server (from one of the root servers [a-m].rootservers.net), initiate a sequence of queries for the IP address for cse.uconn.edu by using dig. Show the list of the names of DNS servers in the delegation chain in answering your query. Please include screenshots.
1

b. Repeat part a) for google.com and amazon.com. Please include screenshots.
3. Email and SMTP (10 points). What is the difference between MAIL FROM: in SMTP and FROM: in the mail message itself? Use an example to explain the difference.
4. Wireshark labs (30 points). Work on DNS Wireshark. Finish the questions (with appropriate screenshots or markings on how you got the answers).
5. Socket programming (20 points). The goal of this problem is to help you get ready for the first programming assignment, which will be assigned after this homework.
¥ Set up environment. You will need to have an environment that you can run python. Ideally, you want to run python3.
¥ Test simple sample code. You can first test a simple version of echo-server and echo-client (attached to this homework) that does not have much in handling errors. Run the server in one terminal. Start a client in another terminal. After that, start another client. (1) Use screenshots to show what you have done and describe the clientsÕ port numbers. (2) Modify the source code so that the client requires entering a phrase from the keyboard. Again use screenshots to show what you have done (include the source code of the client that you have modified).
¥ Test sample code with exception handling. Test echo- server-better and echo-client-better (attached to this homework) that include code in handling errors and has more elaborate code. The comment in the code suggests using python3, but you can run the code using python. Run the server in one terminal. Start a client in another terminal. (1) Run the client as python echo-client-better.py. Why is it not working? Please be very specific in explaining what is wrong. (2) Run the client in an- other way to make it talk to the server successfully. Describe the command line to run the client properly.
2