|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #71293 File upload is not cancelled using session.upload_progress
Submitted: 2016-01-05 23:24 UTC Modified: 2017-10-24 06:05 UTC
Avg. Score:3.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: pfenderd at bellsouth dot net Assigned:
Status: Open Package: Session related
PHP Version: 7.0.1 OS: Windows 7
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: pfenderd at bellsouth dot net
New email:
PHP Version: OS:


 [2016-01-05 23:24 UTC] pfenderd at bellsouth dot net
According to the PHP documentation about session.upload.progress, a file upload can be cancelled by setting
$_SESSION[$key]["cancel_upload"] = TRUE;

As far as PHP session data is concerned, the upload was cancelled and the data in $_FILES indicates that no file data is avaliable.

However, according to my network monitor the browser does not stop sending the file.  It sends the entire file even though the transfer should have stopped.  That means that the form processing cannot continue to the next step until all the file data has been uploaded, which could be several minutes for a large file.

Either this is a bug in the code that needs to be fixed or the documentation should be fixed to say that the upload will not be stopped but the file data will not be available because of the cancel request.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-01-07 07:11 UTC]
-Status: Open +Status: Feedback
 [2016-01-07 07:11 UTC]
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc. If the script requires a 
database to demonstrate the issue, please make sure it creates 
all necessary tables, stored procedures etc.

Please avoid embedding huge scripts into the report.

 [2016-01-17 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 [2016-01-17 22:18 UTC] pfenderd at bellsouth dot net
-Status: No Feedback +Status: Closed
 [2016-01-17 22:18 UTC] pfenderd at bellsouth dot net
To demonstrate the problem, I have made available a set of 4 files that can be downloaded from

This problem cannot be explained with just a short piece of code.
 [2016-02-19 05:13 UTC] pfenderd at bellsouth dot net
-Status: Closed +Status: Assigned
 [2016-02-19 05:13 UTC] pfenderd at bellsouth dot net
I added a link for files to demonstrate the problem.
 [2017-10-24 06:05 UTC]
-Status: Assigned +Status: Open
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Tue Jun 22 15:01:24 2021 UTC