By popular request you can now get automatically generated one-page versions of this document. Since I don't have an HTML to PS filter you have to settle for HTML with possibly dysfunctional links or plain text. This set of documents was generated by Genrep. The focus is on defensive programming techniques that will prevent the abuse of CGI scripts. People can use poorly written CGI scripts to read files that should remain secret from the general public, get shell access on machines running CGIs or simply make the CGI host unusable.
Careful programming can prevent most kinds of harm.
The content is derived from in-person tutorials that used to be given to people that wanted CGI access on calum. The tutorials began to take over one and a half hours so the online version was written to save time. It has grown considerably since its inception. It is assumed that the reader has permission to execute CGI scripts on some server. Particular importance will be attached to the case where CGIs run with the same userid as the CGI writer.