NetProg Spring 2004 HW4

Homework 4: CGI Search Engine
Due Date: March 30 at 11:59PM
Remote Due Date: April 8th

Submit to WebCT drop box.

Late Penalty: 10%/day


HW4 can be done in any language you want! The CS department web server (cgi.cs.rpi.edu) can support C, C++, Perl, PHP and probably a few others. If you can provide your own server - feel free to use whatever language you want.

Project Description

Your assignment is to write a CGI based web search engine! Since we don't really have a database that could be used to find all web pages with a given phrase, we will cheat and use an external search engine to do the work. Your CGI program should receive a search query and then issue an HTTP request to your favorite search engine (I'd suggest using google), gather the results (the HTTP response), do a little parsing and re-formating and send the results back to the client. As far as the client is concerned, you are providing a search engine. In reality, your program is simply using an existing search engine to do the work.

There is a simple demo of what is expected available at: http://monte.cs.rpi.edu/~hollingd/netprog/npoogle/

IMPORTANT!: The machine cgi.cs.rpi.edu (cgi2.cs.rpi.edu) is running FreeBSD, so if you are writing a CGI in C or C++, you should develop your code on freebsd.remote.cs.rpi.edu, not on a Sun!


Deliverables

You must submit all the source code used for your search engine and a link to your live CGI program (so we can test it out). We can a script that will extract the link from your README file, so make sure you provide the link according to the exact instructions below.

You must include in your submission a file named README that includes your name and a brief description of your submission, including the name of each file submitted along with a one line description of what is in the file. The first line of this file should contain an absolute URL that indicates where your CGI program is (so we can test it out). This first line must not contain anything other than the URL!

If your code is not complete, tell us what works and what doesn't. If you are submitting code that does not compile, please tell us that as well. If any of your code was written by someone else, you are required to tell us about it (this must also be documented in the code itself). Finally, feel free to include a description of any problems you had or anything else you think might be helpful to us.


Grading

Your project will be tested to make sure it works properly. Will will use a standard web client, to test your server, and will try various search strings using the form you provide. We will also send requests (using a browser) with nonsense query strings so make sure that your CGI program does not do something dangerous based on the query string entered.

Your grade will depend on the functionality (75%) and the code quality (25%).


Submitting your files

Submission of your homework is via WebCT dropbox for HW4. Don't send compiled code!


Resources/Links