From 1ff64327868cc6153090905ccd458014b8bbc08f Mon Sep 17 00:00:00 2001 From: Scott Gauthreaux Date: Sat, 18 Mar 2017 16:59:53 -0700 Subject: [PATCH] Fixed markdown on README Fixed headings (## requires a space) and changed
 tags to ``` for markdown instead of HTML.
---
 README.md | 32 ++++++++++++++++----------------
 1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/README.md b/README.md
index 6c78a09..118a28b 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
 # CSCI540-ConcurrentWebProxy
 
-##Introduction
+## Introduction
 A Web proxy is a program that acts as a middleman between a Web browser and an end server. Instead of contacting the end server directly to get a Web page, the browser contacts the proxy, which forwards the request on to the end server. When the end server replies to the proxy, the proxy sends the reply on to the browser.
 
 Proxies are used for many purposes. Sometimes proxies are used in firewalls, such that the proxy is the only way for a browser inside the firewall to contact an end server outside. The proxy may do translation on the page, for instance, to make it viewable on a Web-enabled cell phone. Proxies are also used as anonymizers. By stripping a request of all identifying information, a proxy can make the browser anonymous to the end server. Proxies can even be used to cache Web objects, by storing a copy of, say, an image when a request for it is first made, and then serving that image in response to future requests rather than going to the end server.
@@ -9,11 +9,11 @@ In this lab, you will write a concurrent Web proxy that logs requests. In the fi
 
 In the second part of the lab, you will upgrade your proxy so that it uses threads to deal with multiple clients concurrently. This part will give you some experience with concurrency and synchronization, which are crucial computer systems concepts.
 
-##Logistics
+## Logistics
 
 The only handin will be electronic. Any clarifications and revisions to the assignment will be posted on the Piazza discussion board.
 
-##Hand Out Instructions
+## Hand Out Instructions
 
 Start by cloning the project files to a (protected) directory in which you plan to do your work. The project has the following files:
 
@@ -24,41 +24,41 @@ Start by cloning the project files to a (protected) directory in which you plan
 
 Your *proxy.c* file may call any function in the *csapp.c* file. However, since you are only handing in a single *proxy.c* file, please don’t modify the *csapp.c* file. If you want different versions of functions in *csapp.c* (see the Hints section), write new functions in the *proxy.c* file.
 
-##Part I: Implementing a Sequential Web Proxy
+## Part I: Implementing a Sequential Web Proxy
 In this part you will implement a sequential logging proxy. Your proxy should open a socket and listen for a connection request. When it receives a connection request, it should accept the connection, read the HTTP request, and parse it to determine the name of the end server. It should then open a connection to the end server, send it the request, receive the reply, and forward the reply to the browser if the request is not blocked.
 
 Since your proxy is a middleman between client and end server, it will have elements of both. It will act as a server to the web browser, and as a client to the end server. Thus you will get experience with both client and server programming.
 
-###Logging
+### Logging
 Your proxy should keep track of all requests in a log file named *proxy.log*. Each log file entry should be a file of the form:
 
-
+```
 Date: browserIP URL size
-
+``` where *browserIP* is the IP address of the browser, *URL* is the URL asked for, *size* is the size in bytes of the object that was returned. For instance: -
+```
 Sun 27 Oct 2002 02:51:02 EST: 128.2.111.38 http://www.cs.cmu.edu/ 34314
-
+``` Note that *size* is essentially the number of bytes received from the end server, from the time the connection is opened to the time it is closed. Only requests that are met by a response from an end server should be logged. We have provided the function *format_log_entry* in *proxy.c* to create a log entry in the required format. -###Port Numbers +### Port Numbers You proxy should listen for its connection requests on the port number passed in on the command line: -
+```
 unix> ./proxy 15213
-
+``` You may use any port number *p*, where *1024