PDA

View Full Version : Problem with apache/php file upload.



LausBrandt
16-Mar-2012, 11:07
Hi

I'm having a wierd problem with file uploads with apache/php5.3 on a SLES 11 SP2
When I try to upload a file PHP only pick up the files original name ($_FILES['name']), and not alle the other vars i need.

I have checked and double cheched my php.ini both for upload max file, put max size, file upload enabled etc.

Does anybody have an idea what is going on?

Here is the script I used to test it:
<?php
if(isset($_FILES)) {
var_dump($_FILES);
}
?>
<!-- The data encoding type, enctype, MUST be specified as below -->
<form enctype="multipart/form-data" action="/" method="POST">
<!-- MAX_FILE_SIZE must precede the file input field -->
<input type="hidden" name="MAX_FILE_SIZE" value="30000" />
<!-- Name of input element determines name in $_FILES array -->
Send this file: <input name="userfile" type="file" />
<input type="submit" value="Send File" />
</form>

And it gives me:
array(1) { ["userfile"]=> array(1) { ["name"]=> string(8) "test.txt" } }

meikestone
20-Mar-2012, 11:00
Hi

I'm having a wierd problem with file uploads with apache/php5.3 on a SLES 11 SP2
When I try to upload a file PHP only pick up the files original name ($_FILES['name']), and not alle the other vars i need.

I have checked and double cheched my php.ini both for upload max file, put max size, file upload enabled etc.

Does anybody have an idea what is going on?

Here is the script I used to test it:


Have the same ugly Problem, made a bug report in Bugzilla:
https://bugzilla.novell.com/show_bug.cgi?id=753009

Maybe someone other can help us quick?

Kindly regards Meike

jmozdzen
21-Mar-2012, 17:57
Meike,

that Bugzilla report is classified as openSuSE (probably due to access restrictions for your account), you give no hint in that report that you're actually running SLES11SP2 and have spared all and any description (just the link to this thread). Therefore, while I'm no frequent visitor of the SuSE Bugzilla, I wouldn't expect too much of a response there... out of pure politeness, you might at least have copied the original description, together with the test case PHP script.

Just my 2 cents,
Jens

meikestone
23-Mar-2012, 16:44
Meike,

that Bugzilla report is classified as openSuSE (probably due to access restrictions for your account), you give no hint in that report that you're actually running SLES11SP2 and have spared all and any description (just the link to this thread). Therefore, while I'm no frequent visitor of the SuSE Bugzilla, I wouldn't expect too much of a response there... out of pure politeness, you might at least have copied the original description, together with the test case PHP script.

Just my 2 cents,
Jens

Jens, you are right - I'm sorry . It was not my intention to be impolite and yes, the informations are really sparsely... I only would not "steal" the script from other ...

Meike

pallaert
29-Oct-2012, 12:05
Have the same ugly Problem, made a bug report in Bugzilla:
https://bugzilla.novell.com/show_bug.cgi?id=753009


Experiencing the same issue, but bugzilla tells me that "You are not authorized to access bug #753009."
When and how is it going to be solved, and why isn't this bug report public?

Kind regards,
Patrick Allaert

jmozdzen
29-Oct-2012, 12:34
Hi Patrick,

seems like someone at SuSE/Novell took over that ticket and maybe assigned it to a SLES product group. From my experience, Novell doesn't want to offer free public access to the SLES bug list, but rather limit that to customers with certain levels of (money-involving) support plans.

Regards,
Jens

LausBrandt
29-Oct-2012, 12:46
The problem was solved around 10. April along with a "security" fix.
I don't know if it has reappeared since i don't use SLES anymore.

The problem back then was easy to reproduce with parse_str(), since it was affected as well.