From 1e98af0796299d35f920da8d23228789dbe20e58 Mon Sep 17 00:00:00 2001 From: cenarium Date: Mon, 23 Nov 2015 09:07:09 +0100 Subject: [PATCH] Remove proxyunbannable from core This removes the userright 'proxyunbannable' from core, because it has no uses. It is never checked for users with 'ipblock-exempt', yet all usergroups with 'proxyunbannable' also have 'ipblock-exempt'. Bug: T75414 Change-Id: I1e4f6ca439c0274af89f3280fbc519df2b68312c --- includes/DefaultSettings.php | 1 - includes/user/User.php | 6 +----- languages/i18n/en.json | 1 - languages/i18n/qqq.json | 1 - 4 files changed, 1 insertion(+), 8 deletions(-) diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index c9b0e36eac..684e392699 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -4894,7 +4894,6 @@ $wgGroupPermissions['sysop']['patrol'] = true; $wgGroupPermissions['sysop']['autopatrol'] = true; $wgGroupPermissions['sysop']['protect'] = true; $wgGroupPermissions['sysop']['editprotected'] = true; -$wgGroupPermissions['sysop']['proxyunbannable'] = true; $wgGroupPermissions['sysop']['rollback'] = true; $wgGroupPermissions['sysop']['upload'] = true; $wgGroupPermissions['sysop']['reupload'] = true; diff --git a/includes/user/User.php b/includes/user/User.php index 91d4b74920..1029089bbd 100644 --- a/includes/user/User.php +++ b/includes/user/User.php @@ -151,7 +151,6 @@ class User implements IDBAccessObject { 'patrol', 'patrolmarks', 'protect', - 'proxyunbannable', 'purge', 'read', 'reupload', @@ -1521,9 +1520,7 @@ class User implements IDBAccessObject { $block = Block::newFromTarget( $this, $ip, !$bFromSlave ); // Proxy blocking - if ( !$block instanceof Block && $ip !== null && !$this->isAllowed( 'proxyunbannable' ) - && !in_array( $ip, $wgProxyWhitelist ) - ) { + if ( !$block instanceof Block && $ip !== null && !in_array( $ip, $wgProxyWhitelist ) ) { // Local list if ( self::isLocallyBlockedProxy( $ip ) ) { $block = new Block; @@ -1542,7 +1539,6 @@ class User implements IDBAccessObject { if ( !$block instanceof Block && $wgApplyIpBlocksToXff && $ip !== null - && !$this->isAllowed( 'proxyunbannable' ) && !in_array( $ip, $wgProxyWhitelist ) ) { $xff = $this->getRequest()->getHeader( 'X-Forwarded-For' ); diff --git a/languages/i18n/en.json b/languages/i18n/en.json index ed97a365f9..c4276b81b9 100644 --- a/languages/i18n/en.json +++ b/languages/i18n/en.json @@ -1181,7 +1181,6 @@ "right-blockemail": "Block a user from sending email", "right-hideuser": "Block a username, hiding it from the public", "right-ipblock-exempt": "Bypass IP blocks, auto-blocks and range blocks", - "right-proxyunbannable": "Bypass automatic blocks of proxies", "right-unblockself": "Unblock oneself", "right-protect": "Change protection levels and edit cascade-protected pages", "right-editprotected": "Edit pages protected as \"{{int:protect-level-sysop}}\"", diff --git a/languages/i18n/qqq.json b/languages/i18n/qqq.json index 40696c1ce3..0a81731825 100644 --- a/languages/i18n/qqq.json +++ b/languages/i18n/qqq.json @@ -1356,7 +1356,6 @@ "right-blockemail": "{{doc-right|blockemail}}", "right-hideuser": "{{doc-right|hideuser}}\nThis user right is part of the [[mw:RevisionDelete|RevisionDelete]] feature.\nIt can be given to the group {{msg-mw|group-suppress}}, although that group is disabled by default.\n\nSee also\n* {{msg-mw|right-suppressionlog}}\n* {{msg-mw|right-suppressrevision}}\n* {{msg-mw|right-deletelogentry}}\n* {{msg-mw|right-deleterevision}}", "right-ipblock-exempt": "{{doc-right|ipblock-exempt}}\nThis user automatically bypasses IP blocks, auto-blocks and range blocks - so I presume - but I am uncertain", - "right-proxyunbannable": "{{doc-right|proxyunbannable}}", "right-unblockself": "{{doc-right|unblockself}}", "right-protect": "{{doc-right|protect}}", "right-editprotected": "{{doc-right|editprotected}}\nRefers to {{msg-mw|Protect-level-sysop}}.\n\nSee also:\n* {{msg-mw|Right-editsemiprotected}}", -- 2.20.1