Page MenuHomePhabricator

$wgUploadMaintenance is ignored during file uploads
Open, Needs TriagePublic


When $wgUploadMaintenance is set to true, it should prevent any modifications from the upload repository: uploads (and reuploads), deletions, file renames.

Upon deletion it correctly displays an error stating the repo is in maintenance mode. However, the upload form doesn't give any warning, and uploading a file actually succeeds.$wgUploadMaintenance

Reproduced on MediaWiki 1.30

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Okay, I read from the documentation that this setting is "To disable file delete/restore temporarily. " This makes the variable useless.

I don't see a point in allowing uploads while denying deletes/restores, specially since the later usually requires more specific permissions.

From r56215: Note that $wgEnableUploads really should be disabled too or it'll be a bit silly. ;)

I'd expect a centralized way to set uploads to readonly

FileBackend seems to have a ReadOnlyReason[1], but I'm not able to see how to set up easily


Vvjjkkii renamed this task from $wgUploadMaintenance is ignored during file uploads to auaaaaaaaa.Jul 1 2018, 1:03 AM
Vvjjkkii triaged this task as High priority.
Vvjjkkii updated the task description. (Show Details)
Vvjjkkii removed a subscriber: Aklapper.
CommunityTechBot renamed this task from auaaaaaaaa to $wgUploadMaintenance is ignored during file uploads.Jul 2 2018, 5:02 AM
CommunityTechBot raised the priority of this task from High to Needs Triage.
CommunityTechBot updated the task description. (Show Details)
CommunityTechBot added a subscriber: Aklapper.