SlideShare uma empresa Scribd logo
1 de 6
To understand client-server communication via sockets.
To gain exposure to the basic operations of a Web server and
client.
To explore basic structures of HTTP messages.
Due: April 14, 2020 11:59pm Project Description
In this project, you will be developing a multithreaded Web
server and a simple web client. The Web server and Web client
communicate using a text-based protocol called HTTP
(Hypertext Transfer Protocol).
Requirements for the Web server
The server is able to handle multiple requests concurrently.
This means the implementation is multithreaded. In the main
thread, the server listens to a specified port, e.g., 8080. Upon
receiving an HTTP request, the server sets up a TCP connection
to the requesting client and serves the request in a separate
thread. After sending the response back to the client, it closes
the connection.
The server is assumed to work with HTTP GET messages. If
the requested file exists, the server responds with “HTTP/1.1
200 OK” together with the requested page to the client,
otherwise it sends a corresponding error message, e.g.,
“HTTP/1.1 404 Not Found” or “HTTP/1.1 400 Bad Request”.
If running the server program using command line, the
syntax should be: server_code_name []
where the optional is the port on which the server is listening
to connections from
clients. If the port number is not entered, the default port 8080
is used.
You can test your Web server implementation on your local
machine using a Web browser, e.g.,
Internet Explorer, Firefox, or Chrome. You need to specify the
used port number within the URL, for example,
http://localhost
:
8080/index.htm
If omitting the port number portion, i.e., 8080, the browser will
use the default port 80.
The server should response with a default page when users
do not enter a specific page in the URL,
for example,
http://localhost:8080/
It should also work when the request includes a path to the
requested file, for example,
http://localhost:8080/path/to/file/example.htm
You should display/log the request and header lines of
request messages on the server for the purpose of debugging.
Requirements for the simple Web client
The client is able to connect to the server via a socket and to
request a page on the server.
Upon receipt of the response message from the server, the
client extracts and displays/logs the
message status, and then retrieves the page content from the
message body.
g command line, the syntax
should be:
client_code_name [] []
where the is the IP address or name of the Web server, e.g.,
127.0.0.1 or localhost for the server running on the local
machine. The optional is the port on which the server is
listening to connections from clients. If the port number is not
entered, the default port 8080 is used. The optional is the name
of the requested file, which may include the path to the file. If
the file name is not entered, the default file “index.htm” is
used.
Notes:
This is an individual project.
You can use the programming language of your choice. (You
may get more help with Java or Python.)
You may use the skeleton code for the server provided in the
textbook’s companion website for reference. You may also want
to refer to the textbook, chapter 2, section 2.2.3, for more
details on HTTP message format and section 2.7, for socket
programming.
The source codes should be well documented to make it
easier for the TA to follow.
Submission Guidelines
Submit a single zipped file with the naming convention _.zip
which consists of:
d run
your codes. You must mention the IDE as well as any packages
that are required to run the codes.
Do NOT include any runnable executable (binary) program.
Make sure your name and your SAU ID are also listed in the
readme file and in comments at the
beginning of your source files.
Upload the zipped file via
Canvas
. Please strictly follow the naming convention of the zipped file
and the subject title.
Late submission will be accepted with a 10-point deduction
for each extra day.
Additional Requirements/Instructions
Complete documentation and instructions for running the
codes are recommended, otherwise you may be asked to come
give the TA a demo if he is not able to run your programs from
the instructions provided.
If you are using any code from some external source or book,
you MUST mention it explicitly in the codes as well as the
readme file. Otherwise, it will be considered plagiarism and
your project will not be evaluated.
You can discuss with other classmates on steps/algorithms to
implement the project. However, the source codes must be
written yourself.

Mais conteúdo relacionado

Semelhante a   To understand client-server communication via sockets. .docx

692015 programming assignment 1 building a multi­threaded w
692015 programming assignment 1 building a multi­threaded w692015 programming assignment 1 building a multi­threaded w
692015 programming assignment 1 building a multi­threaded wsmile790243
 
PHP Training: Module 1
PHP Training: Module 1PHP Training: Module 1
PHP Training: Module 1hussulinux
 
Computer networking mcis 6163 project
Computer networking mcis 6163 projectComputer networking mcis 6163 project
Computer networking mcis 6163 projectAnakinzs
 
Html intake 38 lect1
Html intake 38 lect1Html intake 38 lect1
Html intake 38 lect1ghkadous
 
Server Side Programming
Server Side ProgrammingServer Side Programming
Server Side ProgrammingMilan Thapa
 
Under the Covers with the Web
Under the Covers with the WebUnder the Covers with the Web
Under the Covers with the WebTrevor Lohrbeer
 
Raisa anthony web programming 1st week
Raisa anthony   web programming 1st weekRaisa anthony   web programming 1st week
Raisa anthony web programming 1st weekRaisa Anjani
 
Assignment #2 Lab Exercise – HTTP INT6143, Enterpr.docx
Assignment #2 Lab Exercise – HTTP   INT6143, Enterpr.docxAssignment #2 Lab Exercise – HTTP   INT6143, Enterpr.docx
Assignment #2 Lab Exercise – HTTP INT6143, Enterpr.docxdavezstarr61655
 
Web Server and how we can design app in C#
Web Server and how we can design app  in C#Web Server and how we can design app  in C#
Web Server and how we can design app in C#caohansnnuedu
 
Networking Java Socket Programming
Networking Java Socket ProgrammingNetworking Java Socket Programming
Networking Java Socket ProgrammingMousmi Pawar
 
Web Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdfWeb Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdfRaghunathan52
 
Web Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdfWeb Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdfRaghunathan52
 
Hypertext Transfer Protocol
Hypertext Transfer ProtocolHypertext Transfer Protocol
Hypertext Transfer ProtocolRajan Pandey
 

Semelhante a   To understand client-server communication via sockets. .docx (20)

692015 programming assignment 1 building a multi­threaded w
692015 programming assignment 1 building a multi­threaded w692015 programming assignment 1 building a multi­threaded w
692015 programming assignment 1 building a multi­threaded w
 
PHP Training: Module 1
PHP Training: Module 1PHP Training: Module 1
PHP Training: Module 1
 
Lecture2
Lecture2Lecture2
Lecture2
 
Computer networking mcis 6163 project
Computer networking mcis 6163 projectComputer networking mcis 6163 project
Computer networking mcis 6163 project
 
Html intake 38 lect1
Html intake 38 lect1Html intake 38 lect1
Html intake 38 lect1
 
Server Side Programming
Server Side ProgrammingServer Side Programming
Server Side Programming
 
Under the Covers with the Web
Under the Covers with the WebUnder the Covers with the Web
Under the Covers with the Web
 
Starting With Php
Starting With PhpStarting With Php
Starting With Php
 
Ch-1_.ppt
Ch-1_.pptCh-1_.ppt
Ch-1_.ppt
 
Raisa anthony web programming 1st week
Raisa anthony   web programming 1st weekRaisa anthony   web programming 1st week
Raisa anthony web programming 1st week
 
Assignment #2 Lab Exercise – HTTP INT6143, Enterpr.docx
Assignment #2 Lab Exercise – HTTP   INT6143, Enterpr.docxAssignment #2 Lab Exercise – HTTP   INT6143, Enterpr.docx
Assignment #2 Lab Exercise – HTTP INT6143, Enterpr.docx
 
www and http services
www and http serviceswww and http services
www and http services
 
Web Server and how we can design app in C#
Web Server and how we can design app  in C#Web Server and how we can design app  in C#
Web Server and how we can design app in C#
 
Networking Java Socket Programming
Networking Java Socket ProgrammingNetworking Java Socket Programming
Networking Java Socket Programming
 
5-WebServers.ppt
5-WebServers.ppt5-WebServers.ppt
5-WebServers.ppt
 
Web Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdfWeb Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdf
 
Web Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdfWeb Technologies Notes - TutorialsDuniya.pdf
Web Technologies Notes - TutorialsDuniya.pdf
 
Http
HttpHttp
Http
 
Socket
SocketSocket
Socket
 
Hypertext Transfer Protocol
Hypertext Transfer ProtocolHypertext Transfer Protocol
Hypertext Transfer Protocol
 

Mais de tamicawaysmith

(No Plagiarism) Explain the statement Although many leading organi.docx
(No Plagiarism) Explain the statement Although many leading organi.docx(No Plagiarism) Explain the statement Although many leading organi.docx
(No Plagiarism) Explain the statement Although many leading organi.docxtamicawaysmith
 
 What made you choose this career path What advice do you hav.docx
 What made you choose this career path What advice do you hav.docx What made you choose this career path What advice do you hav.docx
 What made you choose this career path What advice do you hav.docxtamicawaysmith
 
 Patient Population The student will describe the patient populati.docx
 Patient Population The student will describe the patient populati.docx Patient Population The student will describe the patient populati.docx
 Patient Population The student will describe the patient populati.docxtamicawaysmith
 
 Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx
 Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx
 Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docxtamicawaysmith
 
 In depth analysis of your physical fitness progress  Term p.docx
 In depth analysis of your physical fitness progress  Term p.docx In depth analysis of your physical fitness progress  Term p.docx
 In depth analysis of your physical fitness progress  Term p.docxtamicawaysmith
 
 Information systems infrastructure evolution and trends  Str.docx
 Information systems infrastructure evolution and trends  Str.docx Information systems infrastructure evolution and trends  Str.docx
 Information systems infrastructure evolution and trends  Str.docxtamicawaysmith
 
⦁One to two paragraph brief summary of the book. ⦁Who is the.docx
⦁One to two paragraph brief summary of the book. ⦁Who is the.docx⦁One to two paragraph brief summary of the book. ⦁Who is the.docx
⦁One to two paragraph brief summary of the book. ⦁Who is the.docxtamicawaysmith
 
101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx
101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx
101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docxtamicawaysmith
 
100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx
100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx
100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docxtamicawaysmith
 
100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx
100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx
100635307FLORIDABUILDINGCODE Sixth Edition(2017).docxtamicawaysmith
 
1003Violence Against WomenVolume 12 Number 11Novembe.docx
1003Violence Against WomenVolume 12 Number 11Novembe.docx1003Violence Against WomenVolume 12 Number 11Novembe.docx
1003Violence Against WomenVolume 12 Number 11Novembe.docxtamicawaysmith
 
102120151De-Myth-tifying Grading in Sp.docx
102120151De-Myth-tifying Grading             in Sp.docx102120151De-Myth-tifying Grading             in Sp.docx
102120151De-Myth-tifying Grading in Sp.docxtamicawaysmith
 
100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx
100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx
100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docxtamicawaysmith
 
100 words agree or disagree to eac questions Q 1.As her .docx
100 words agree or disagree to eac questions Q 1.As her .docx100 words agree or disagree to eac questions Q 1.As her .docx
100 words agree or disagree to eac questions Q 1.As her .docxtamicawaysmith
 
101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx
101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx
101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docxtamicawaysmith
 
100 words per question, no references needed or quotations. Only a g.docx
100 words per question, no references needed or quotations. Only a g.docx100 words per question, no references needed or quotations. Only a g.docx
100 words per question, no references needed or quotations. Only a g.docxtamicawaysmith
 
100A 22 4 451A 1034 51B 1000 101C 1100 11D 112.docx
100A 22 4 451A 1034  51B 1000 101C 1100  11D 112.docx100A 22 4 451A 1034  51B 1000 101C 1100  11D 112.docx
100A 22 4 451A 1034 51B 1000 101C 1100 11D 112.docxtamicawaysmith
 
10122018Week 5 Required Reading and Supplementary Materials - .docx
10122018Week 5 Required Reading and Supplementary Materials - .docx10122018Week 5 Required Reading and Supplementary Materials - .docx
10122018Week 5 Required Reading and Supplementary Materials - .docxtamicawaysmith
 
101416 526 PMAfter September 11 Our State of Exception by .docx
101416 526 PMAfter September 11 Our State of Exception by .docx101416 526 PMAfter September 11 Our State of Exception by .docx
101416 526 PMAfter September 11 Our State of Exception by .docxtamicawaysmith
 
100 words per question, no references needed or quotations. Only.docx
100 words per question, no references needed or quotations. Only.docx100 words per question, no references needed or quotations. Only.docx
100 words per question, no references needed or quotations. Only.docxtamicawaysmith
 

Mais de tamicawaysmith (20)

(No Plagiarism) Explain the statement Although many leading organi.docx
(No Plagiarism) Explain the statement Although many leading organi.docx(No Plagiarism) Explain the statement Although many leading organi.docx
(No Plagiarism) Explain the statement Although many leading organi.docx
 
 What made you choose this career path What advice do you hav.docx
 What made you choose this career path What advice do you hav.docx What made you choose this career path What advice do you hav.docx
 What made you choose this career path What advice do you hav.docx
 
 Patient Population The student will describe the patient populati.docx
 Patient Population The student will describe the patient populati.docx Patient Population The student will describe the patient populati.docx
 Patient Population The student will describe the patient populati.docx
 
 Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx
 Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx
 Dr. Paul Murray  Bessie Coleman  Jean-Bapiste Bell.docx
 
 In depth analysis of your physical fitness progress  Term p.docx
 In depth analysis of your physical fitness progress  Term p.docx In depth analysis of your physical fitness progress  Term p.docx
 In depth analysis of your physical fitness progress  Term p.docx
 
 Information systems infrastructure evolution and trends  Str.docx
 Information systems infrastructure evolution and trends  Str.docx Information systems infrastructure evolution and trends  Str.docx
 Information systems infrastructure evolution and trends  Str.docx
 
⦁One to two paragraph brief summary of the book. ⦁Who is the.docx
⦁One to two paragraph brief summary of the book. ⦁Who is the.docx⦁One to two paragraph brief summary of the book. ⦁Who is the.docx
⦁One to two paragraph brief summary of the book. ⦁Who is the.docx
 
101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx
101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx
101018, 6(27 PMPage 1 of 65httpsjigsaw.vitalsource.co.docx
 
100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx
100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx
100.0 Criteria10.0 Part 1 PLAAFP The PLAAFP thoroughly an.docx
 
100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx
100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx
100635307FLORIDABUILDINGCODE Sixth Edition(2017).docx
 
1003Violence Against WomenVolume 12 Number 11Novembe.docx
1003Violence Against WomenVolume 12 Number 11Novembe.docx1003Violence Against WomenVolume 12 Number 11Novembe.docx
1003Violence Against WomenVolume 12 Number 11Novembe.docx
 
102120151De-Myth-tifying Grading in Sp.docx
102120151De-Myth-tifying Grading             in Sp.docx102120151De-Myth-tifying Grading             in Sp.docx
102120151De-Myth-tifying Grading in Sp.docx
 
100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx
100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx
100.0 Criteria30.0 Flowchart ContentThe flowchart skillful.docx
 
100 words agree or disagree to eac questions Q 1.As her .docx
100 words agree or disagree to eac questions Q 1.As her .docx100 words agree or disagree to eac questions Q 1.As her .docx
100 words agree or disagree to eac questions Q 1.As her .docx
 
101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx
101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx
101118, 4(36 PMCollection – MSA 603 Strategic Planning for t.docx
 
100 words per question, no references needed or quotations. Only a g.docx
100 words per question, no references needed or quotations. Only a g.docx100 words per question, no references needed or quotations. Only a g.docx
100 words per question, no references needed or quotations. Only a g.docx
 
100A 22 4 451A 1034 51B 1000 101C 1100 11D 112.docx
100A 22 4 451A 1034  51B 1000 101C 1100  11D 112.docx100A 22 4 451A 1034  51B 1000 101C 1100  11D 112.docx
100A 22 4 451A 1034 51B 1000 101C 1100 11D 112.docx
 
10122018Week 5 Required Reading and Supplementary Materials - .docx
10122018Week 5 Required Reading and Supplementary Materials - .docx10122018Week 5 Required Reading and Supplementary Materials - .docx
10122018Week 5 Required Reading and Supplementary Materials - .docx
 
101416 526 PMAfter September 11 Our State of Exception by .docx
101416 526 PMAfter September 11 Our State of Exception by .docx101416 526 PMAfter September 11 Our State of Exception by .docx
101416 526 PMAfter September 11 Our State of Exception by .docx
 
100 words per question, no references needed or quotations. Only.docx
100 words per question, no references needed or quotations. Only.docx100 words per question, no references needed or quotations. Only.docx
100 words per question, no references needed or quotations. Only.docx
 

Último

Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991RKavithamani
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphThiyagu K
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...RKavithamani
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 

Último (20)

Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 

  To understand client-server communication via sockets. .docx

  • 1. To understand client-server communication via sockets. To gain exposure to the basic operations of a Web server and client. To explore basic structures of HTTP messages. Due: April 14, 2020 11:59pm Project Description In this project, you will be developing a multithreaded Web server and a simple web client. The Web server and Web client communicate using a text-based protocol called HTTP (Hypertext Transfer Protocol). Requirements for the Web server The server is able to handle multiple requests concurrently. This means the implementation is multithreaded. In the main thread, the server listens to a specified port, e.g., 8080. Upon receiving an HTTP request, the server sets up a TCP connection to the requesting client and serves the request in a separate thread. After sending the response back to the client, it closes the connection. The server is assumed to work with HTTP GET messages. If
  • 2. the requested file exists, the server responds with “HTTP/1.1 200 OK” together with the requested page to the client, otherwise it sends a corresponding error message, e.g., “HTTP/1.1 404 Not Found” or “HTTP/1.1 400 Bad Request”. If running the server program using command line, the syntax should be: server_code_name [] where the optional is the port on which the server is listening to connections from clients. If the port number is not entered, the default port 8080 is used. You can test your Web server implementation on your local machine using a Web browser, e.g., Internet Explorer, Firefox, or Chrome. You need to specify the used port number within the URL, for example, http://localhost : 8080/index.htm If omitting the port number portion, i.e., 8080, the browser will use the default port 80. The server should response with a default page when users do not enter a specific page in the URL, for example, http://localhost:8080/
  • 3. It should also work when the request includes a path to the requested file, for example, http://localhost:8080/path/to/file/example.htm You should display/log the request and header lines of request messages on the server for the purpose of debugging. Requirements for the simple Web client The client is able to connect to the server via a socket and to request a page on the server. Upon receipt of the response message from the server, the client extracts and displays/logs the message status, and then retrieves the page content from the message body. g command line, the syntax should be: client_code_name [] [] where the is the IP address or name of the Web server, e.g., 127.0.0.1 or localhost for the server running on the local
  • 4. machine. The optional is the port on which the server is listening to connections from clients. If the port number is not entered, the default port 8080 is used. The optional is the name of the requested file, which may include the path to the file. If the file name is not entered, the default file “index.htm” is used. Notes: This is an individual project. You can use the programming language of your choice. (You may get more help with Java or Python.) You may use the skeleton code for the server provided in the textbook’s companion website for reference. You may also want to refer to the textbook, chapter 2, section 2.2.3, for more details on HTTP message format and section 2.7, for socket programming. The source codes should be well documented to make it easier for the TA to follow. Submission Guidelines Submit a single zipped file with the naming convention _.zip which consists of:
  • 5. d run your codes. You must mention the IDE as well as any packages that are required to run the codes. Do NOT include any runnable executable (binary) program. Make sure your name and your SAU ID are also listed in the readme file and in comments at the beginning of your source files. Upload the zipped file via Canvas . Please strictly follow the naming convention of the zipped file and the subject title. Late submission will be accepted with a 10-point deduction for each extra day. Additional Requirements/Instructions Complete documentation and instructions for running the codes are recommended, otherwise you may be asked to come give the TA a demo if he is not able to run your programs from the instructions provided. If you are using any code from some external source or book, you MUST mention it explicitly in the codes as well as the readme file. Otherwise, it will be considered plagiarism and
  • 6. your project will not be evaluated. You can discuss with other classmates on steps/algorithms to implement the project. However, the source codes must be written yourself.