Fix protection rights usage
authorBrad Jorsch <bjorsch@wikimedia.org>
Fri, 28 Jun 2013 17:20:00 +0000 (13:20 -0400)
committerTim Starling <tstarling@wikimedia.org>
Thu, 4 Jul 2013 05:38:36 +0000 (15:38 +1000)
commitd24779328eabd8d4385fbf780e611879d846d55c
tree71da6e7f25ab88c7e237e070f107a498914eb3ff
parente3e03f53ce8b8317ded937860aadd8a991daaa5d
Fix protection rights usage

It has long been recognized that using the 'protect' right to control
the ability to edit sysop-protected pages is troublesome. r31247 fixed
this by adding an 'editprotected' right, but for some reason in r32164
this was changed to bypass protection completely instead of fixing the
bug identified in r31462.

This patch goes back to do it the right way: editprotected no longer
bypasses all protection, and it is used instead of 'protect' for
controlling access to sysop-protected pages. For good measure, the same
is done with autoconfirmed protection (semiprotection): a new
editsemiprotected right is created instead of overloading the
existing autoconfirmed right.

This also fixes bug 27152 by making editprotected no longer special.

Bug: 13137
Bug: 27152
Change-Id: I6bf650a3fbdab8589ae6945c8c916eafd949e41c
RELEASE-NOTES-1.22
includes/DefaultSettings.php
includes/ProtectionForm.php
includes/Title.php
includes/User.php
includes/WikiPage.php
languages/messages/MessagesEn.php
languages/messages/MessagesQqq.php
maintenance/dictionary/mediawiki.dic
maintenance/language/messages.inc
tests/phpunit/includes/TitlePermissionTest.php