use CGI; my $q = CGI->new(); my $buf_size = 4096; my $file_root = '/home/goldcal/files'; # not in /www! open( my $fh, '<', "$file_root/wlmlm401.exe" ) or die("open failed: $!"); binmode($fh); print $q->header( -type => 'application/exe', -expires => '-1d' ); binmode(STDOUT); my $buf; while ( read($fh, $buf, $buf_size) ) { print $buf; }