It is often necessary for a CGI program to create or modify a file on the
server. This requires that the CGI have write permission where the file resides. Since the web
server runs as user nobody or www it will not always
have permission to modify a file. There are 2 ways to get around that.
Change the permissions on the file or directory to world writable. Bad! Yuck! Ptooey!
Create a common group between the user and the httpd user. This isn't always practical.
Run the CGI with the userid of the file's owner. This is
recommended whether you need to write files or not. By running CGI
programs as their respective owners you can
greatly improve security and accountability.
There are at least a couple of ways to accomplish this option.