http://qs321.pair.com?node_id=97363


in reply to Re: Getting CGI to name a file it returns
in thread Getting CGI to name a file it returns

First you have to actually create a file under your server's DocumentRoot, which could not be as obvisous as it seems if you don't have the permissions.

Second, the file is potentially visible by other users too, and you must remember to erase it. Otherwise the filesystem will fill up and the file would be at other client's perusal.

Third, you must carefully choose how to create the temp dir, or the same problems/race conditions associate to temp files would potentially show up.

Fourth, MIME headers are so cool in this context :-)

Nonetheless your solution is probably the quickest, but a security-proof implementation can be more painful than it seems. <SIGNATURE>-- TIMTOWTDI</SIGNATURE>