Maybe it's just me, but this:


$type = $_GET['type'];
$fileName = $_GET['filename'] . "." . $type;

$mimeType = "application/$type";
        if (strpos($_SERVER['HTTP_USER_AGENT'], 'MSIE 5') or
            strpos($_SERVER['HTTP_USER_AGENT'], 'Opera 7')) $mimeType =
        header("content-disposition: attachment; filename =
        header("content-type: {$mimeType}");

where the link would be download.php?filename=mypdf&type=pdf


looks terribly insecure to me -- I'm allowed to put whatever I want into
the URL until I find something interesting? 

I think I'd start with 


The information contained in this email and any attachment is confidential and
may contain legally privileged or copyright material.   It is intended only for
the use of the addressee(s).  If you are not the intended recipient of this
email, you are not permitted to disseminate, distribute or copy this email or
any attachments.  If you have received this message in error, please notify the
sender immediately and delete this email from your system.  The ABC does not
represent or warrant that this transmission is secure or virus free.   Before
opening any attachment you should check for viruses.  The ABC's liability is
limited to resupplying any email and attachments

List Guidelines:

Reply via email to