Last modified: 2013-04-22 16:16:34 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T40719, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 38719 - FileBackend.php has 1 GB limit, despite $wgMaxUploadSize
FileBackend.php has 1 GB limit, despite $wgMaxUploadSize
Status: RESOLVED WONTFIX
Product: MediaWiki
Classification: Unclassified
Uploading (Other open bugs)
1.19
All All
: Unprioritized minor (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch, patch-need-review
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-26 17:57 UTC by Timothy O'Keefe
Modified: 2013-04-22 16:16 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
FileBackend.php patch (425 bytes, patch)
2012-07-26 17:57 UTC, Timothy O'Keefe
Details
FileBackend.php patch v2 (652 bytes, patch)
2012-07-26 23:32 UTC, Timothy O'Keefe
Details
FileBackend.php patch v3 (1.11 KB, patch)
2012-08-31 14:15 UTC, Timothy O'Keefe
Details

Description Timothy O'Keefe 2012-07-26 17:57:15 UTC
See patch.

FileBackend.php has a hard-coded limit ($this->maxFileSize) of ~1 GB. 

If LocalSettings.php $wgMaxUploadSize is set > 1 GB, the file will be blocked by FileBackend.php.

The patch adds a condition to defer to $GLOBALS['wgMaxUploadSize'] if it is greater than maxFileSize.
Comment 1 Timothy O'Keefe 2012-07-26 17:57:59 UTC
Created attachment 10897 [details]
FileBackend.php patch
Comment 2 Bryan Tong Minh 2012-07-26 20:28:06 UTC
$wgMaxUploadSize is not necessarily an integer, but could also be an array of integers.
Comment 3 Timothy O'Keefe 2012-07-26 23:32:26 UTC
Created attachment 10899 [details]
FileBackend.php patch v2

See updated patch. Should cover more bases.
Comment 4 Sumana Harihareswara 2012-08-30 15:36:00 UTC
Comment on attachment 10897 [details]
FileBackend.php patch

I presume this is obsoleted by the "v2" patch. :)
Comment 5 Alex Monk 2012-08-30 15:50:29 UTC
Comment on attachment 10899 [details]
FileBackend.php patch v2

Moved to Gerrit change #22038
Comment 6 Sumana Harihareswara 2012-08-30 15:52:11 UTC
Thanks for the patch, Timothy O'Keefe.  It's been moved into our source control system so people can comment on and review it.  You can use https://www.mediawiki.org/wiki/Git/Tutorial to understand more and get a free account.
Comment 7 Sumana Harihareswara 2012-08-30 16:06:51 UTC
Timothy, you have a comment on your code here: https://gerrit.wikimedia.org/r/#/c/22038/1/includes/filebackend/FileBackendStore.php so it would be great if you could respond & resubmit. Thanks!
Comment 8 Timothy O'Keefe 2012-08-31 14:15:25 UTC
Created attachment 11046 [details]
FileBackend.php patch v3

Addressing comment: https://gerrit.wikimedia.org/r/#/c/22038/1/includes/filebackend/FileBackendStore.php
Comment 9 Alex Monk 2012-08-31 14:16:43 UTC
Please put your amendment in Gerrit instead of here.
Comment 10 Alex Monk 2012-09-13 22:15:53 UTC
Hello? Can you request developer access and submit this to Gerrit please?
Comment 11 Alex Monk 2012-10-07 14:34:25 UTC
On the 23rd of September, Aaron Schulz posted this comment on the Gerrit change:
>The limit is 4GiB now, and if it were to be configured, we'd want to use a paramer given to the FileBackend constructor.

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


Navigation
Links