Bug 58473 - php upload broken
Summary: php upload broken
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: php
Version: 7.2
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: Phil Copeland
QA Contact: David Lawrence
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-01-17 18:43 UTC by Fabrice
Modified: 2005-10-31 22:00 UTC (History)
1 user (show)

(edit)
Clone Of:
(edit)
Last Closed: 2002-02-27 14:49:04 UTC


Attachments (Terms of Use)

Description Fabrice 2002-01-17 18:43:30 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; Q312461)

Description of problem:
Internal server error 500 returned after file is uploaded.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.Try the following script
2.
3.
	

Actual Results:  Internal server error 500

Expected Results:  The script should print the file name.

Additional info:

php is run as CGI. php script secured 755.
php version 4.0.6

Problem occured after ISP upgraded to redhat 7.2 and php4.0.6, apache 1.3.20. 
Previous version was working and was 6.1 php 4.0.2 and I don't know about 
apache.

#!/usr/local/bin/php
<HTLM><BODY>
<FORM ENCTYPE="multipart/form-data" ACTION="upload.php"
METHOD=POST>
<INPUT TYPE="hidden" name="MAX_FILE_SIZE"
value="100000">
Send this file: <INPUT NAME="userfile" TYPE="file">
<INPUT TYPE="submit" VALUE="Send File">
</FORM>
<?
echo "\$userfile=".$userfile."<br>";
echo "\$userfile_name=".$userfile_name."<br>";
echo "\$userfile_size=".$userfile_size."<br>";
echo "\$userfile_type=".$userfile_type."<br>";
echo "is_uploaded_file=".is_uploaded_file($userfile)."<br>";
copy($userfile, "testfile");
?>
</BODY></HTML>

Comment 1 Fabrice 2002-01-20 01:28:15 UTC
I have installed 4.0.4pl1 on the same system (just compiling with --with-mysql -
-with-apache --host i386-redhat-linux) and that worked. Unfortunately I can't 
install RPMS so I had to go with the simple compile.

I've opened a bug report with php #15102.

Comment 2 Peter Bowen 2002-02-27 14:21:55 UTC
According to your bugs.php.net bug report, http://bugs.php.net/bug.php?id=15102,
suggests that it is probably fixed in 4.1.*, as 4.0.6 had some file upload bugs.
  Additionally 4.1.2 has a buffer overrun fixed in the file upload code.  Once
4.1.2 is released as an errata, please test to see if this is fixed.

Comment 3 Fabrice 2002-02-27 14:49:00 UTC
sure will, thanks!

Comment 4 Phil Copeland 2002-08-12 18:54:42 UTC
Closing



Note You need to log in before you can comment on or make changes to this bug.