php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62317 Session upload progress returns empty array if files larger than post_max_size
Submitted: 2012-06-13 20:27 UTC Modified: 2013-06-27 19:19 UTC
Votes:2
Avg. Score:4.0 ± 1.0
Reproduced:0 of 0 (0.0%)
From: scott at phphq dot net Assigned:
Status: Wont fix Package: Session related
PHP Version: 5.4.3 OS: Win Server 2003 x86 / IIS 6
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: scott at phphq dot net
New email:
PHP Version: OS:

 

 [2012-06-13 20:27 UTC] scott at phphq dot net
Description:
------------
I am submitting this as a bug because PHP will instantly return an empty $_SESSION 
array if the file size sum of all uploaded files is larger than allowed by 
post_max_size or upload_max_filesize even though the browser continues to upload. 
I would expect that PHP would automatically cancel these uploads, or at least 
return an error so I can use $_SESSION[key]['cancel_upload']; myself. 

I'm on PHP 5.4.3, Win Server 2003 x86, IIS6 as fast_cgi. 
session.upload_progress.cleanup is turned off so I could try and debug this. It's 
not happening because of the cleanup process.

Test script:
---------------
Here is what you can use to duplicate the issue:
http://phphq.net/_upbug/

Expected result:
----------------
I would expect some sort of error.

Actual result:
--------------
Null responce

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-06-27 19:19 UTC] arpad@php.net
-Status: Open +Status: Wont fix
 [2013-06-27 19:19 UTC] arpad@php.net
When files exceed upload_max_filesize, the progress data does return an error. 

However when the content length of the request exceeds post_max_size, a warning is raised and all upload processing is skipped.

In order to provide errors in the progress data in this case, we'd have to keep processing the request just to find out if there's any files to report the errors on.

If you're regularly checking the progress data, it would make sense to consider the absence of any progress data after a certain threshold, an error in itself.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Apr 29 19:01:30 2024 UTC