Bug#602812: I can reproduce it

January 11th, 2011 - 09:30 am ET by Mattias Nordstrom | Report spam
Hi,

This seems to be an actual bug. On a freshly installed Squeeze box
normal PHP applications fail as forms don't work with array fields over
1000 elements. This also happens on my sid development box. I installed
an original source PHP 5.3.3 and there it doesn't happen == works.

My test code:

== BEGIN (filename: form-test.php) =
<html>
<body>

<?php

$count = 2000;

if (!empty($_REQUEST['test'])) {
print "Count: ".count($_REQUEST['test']).", should be $count.<br><br>";
print_r($_REQUEST);

}

?>

<form action="form-test.php" method="post">
<?php


for ($i=0; $i<$count; $i++) {
echo "<input type='hidden' name='test[]' value='$i' />";
}

?>

<input type='submit' name='submit' value='submit'></form>

</body>
</html>

== END =

If this is an actual bug it is quite serious as it can easily cause data
corruption in databases among other things.

Regards,
Mattias Nordström



To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
email Follow the discussionReplies 1 replyReplies Make a reply

Replies

#1 Ondřej Surý
January 12th, 2011 - 04:50 am ET | Report spam
Hi Mattias and Richard,

I was able to confirm that the bug exists in the debian php (and
upstream is fine). I am now in process of testing which patch may
cause this, but it may take while, because Debian's 5.3.3-7 has
accumulated quite a lot of cherry picked upstream patches.

Ondrej

On Tue, Jan 11, 2011 at 15:09, Mattias Nordstrom wrote:
Hi,

This seems to be an actual bug. On a freshly installed Squeeze box
normal PHP applications fail as forms don't work with array fields over
1000 elements. This also happens on my sid development box. I installed
an original source PHP 5.3.3 and there it doesn't happen == works.

My test code:

== BEGIN (filename: form-test.php) =>
<html>
<body>

<?php

$count = 2000;

if (!empty($_REQUEST['test'])) {
print "Count: ".count($_REQUEST['test']).", should be $count.<br><br>";
print_r($_REQUEST);

}

?>

<form action="form-test.php" method="post">
<?php


for ($i=0; $i<$count; $i++) {
 echo "<input type='hidden' name='test[]' value='$i' />";
}

?>

<input type='submit' name='submit' value='submit'></form>

</body>
</html>

== END =>

If this is an actual bug it is quite serious as it can easily cause data
corruption in databases among other things.

Regards,
Mattias Nordström



_______________________________________________
pkg-php-maint mailing list

http://lists.alioth.debian.org/mail...-php-maint






Ondřej Surý
http://blog.rfc1925.org/



To UNSUBSCRIBE, email to
with a subject of "unsubscribe". Trouble? Contact

Similar topics