Answered step by step
Verified Expert Solution
Question
1 Approved Answer
pls help Objective: In this project, we will study how to write socket programming. In addition, we also study a real-world protocol of HTTP. Task:
pls help
Objective: In this project, we will study how to write socket programming. In addition, we also study a real-world protocol of HTTP. Task: Develop a multi-threaded web server. You can develop your code in two stages. In the first stage, you simply display the contents of the HTTP request messages that your web server receives. After this is running properly, you will add the code to generate an appropriate response. The web server needs a log file to record statistics of the client requests. Each request corresponds to one line in the log. Write down client hostname/IP address, access time, requested file name and response type. Your webserver also needs to handle some simple errors, such as webpage not found. You may run the server on your own computer, using the IP address of 127.0.0.1. Define your own port number (don't use 80). A single thread webserver will get partial mark. You can use either Java or C/C++. Your code should be commented appropriately. Include a READMET text file of how to compile and run your program. I would expect to see your server to handle the following ONLY (marks will be deducted if you have more): 1. two request methods, GET, HEAD 2. three respond types, 200 OK, 400 Bad Request, 404 File Not Found 3. handle Last-Modified field and If-Modified-Since headerStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started