ECN No Name Newsletter: January, 1996

The ECN No Name Newsletter is no longer being published. This is an archived issue.

[previous article]

Who Are You And What Do You Want?

NO NAME NEWSLETTER -- January 1996

Kyler B. Laird


http://www.ecn.purdue.edu/WebTool/

These are common questions that Web programs that use the Common Gateway Interface (CGI) ask their callers. Because these functions are used so often, I wrote a utility, WEBTOOL, that makes writing CGI shell scripts easier.

WEBTOOL is a compilation of CGI utilities. WEBTOOL's behavior is determined by the flags it is given. For example, to find out who is calling your page (using the ident protocol), you would use webtool -ident WEBTOOL would then output lines like

IDENT_LPORT='53106'
IDENT_FPORT='80'
IDENT_OPSYS='UNIX'
IDENT_CHARSET=''
IDENT_IDENTIFIER='laird'
Similarly, you can find out what a user wants by parsing the results of a fill-in form. Running webtool -getvars or webtool -postvars will parse the results of a form which uses the GET or POST method.

After you've found out who has called your script and what they want, you can also use WEBTOOL to send some appropriate mail - either *to* you, the owner of the CGI script, or *from* you. Because WEBTOOL makes mail look as though it's from you or the user (instead of user "www"), replies can be made easily without changing the "To:" field.

For more information about WEBTOOL, use the URL http://www.ecn.purdue.edu/WebTool/.


webmaster@ecn.purdue.edu
Last modified: Friday, 12-Sep-97 22:31:57 EST

[HTML Check] HTML