Index: trunk/extensions/CentralAuth/CentralAuthPlugin.php |
— | — | @@ -1,5 +1,4 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | /** |
5 | 4 | * "Attached" accounts always require authentication against the central password. |
6 | 5 | * |
— | — | @@ -7,8 +6,8 @@ |
8 | 7 | * $wgCentralAuthStrict is not set, but they will not have access to any |
9 | 8 | * central password or settings. |
10 | 9 | */ |
| 10 | + |
11 | 11 | class CentralAuthPlugin extends AuthPlugin { |
12 | | - |
13 | 12 | /** |
14 | 13 | * Check whether there exists a user account with the given name. |
15 | 14 | * The name will be normalized to MediaWiki's requirements, so |
— | — | @@ -39,15 +38,17 @@ |
40 | 39 | global $wgCentralAuthAutoMigrate; |
41 | 40 | |
42 | 41 | $central = new CentralAuthUser( $username ); |
43 | | - if( !$central->exists() ) { |
44 | | - wfDebugLog( 'CentralAuth', |
45 | | - "plugin: no global account for '$username'" ); |
| 42 | + if ( !$central->exists() ) { |
| 43 | + wfDebugLog( |
| 44 | + 'CentralAuth', |
| 45 | + "plugin: no global account for '$username'" |
| 46 | + ); |
46 | 47 | return false; |
47 | 48 | } |
48 | 49 | |
49 | 50 | $passwordMatch = $central->authenticate( $password ) == "ok"; |
50 | 51 | |
51 | | - if( $passwordMatch && $wgCentralAuthAutoMigrate ) { |
| 52 | + if ( $passwordMatch && $wgCentralAuthAutoMigrate ) { |
52 | 53 | // If the user passed in the global password, we can identify |
53 | 54 | // any remaining local accounts with a matching password |
54 | 55 | // and migrate them in transparently. |
— | — | @@ -64,9 +65,9 @@ |
65 | 66 | // global exists, local doesn't exist: require global auth -> will autocreate local |
66 | 67 | // global doesn't exist, local doesn't exist: no authentication |
67 | 68 | // |
68 | | - if( !$central->isAttached() ) { |
| 69 | + if ( !$central->isAttached() ) { |
69 | 70 | $local = User::newFromName( $username ); |
70 | | - if( $local && $local->getId() ) { |
| 71 | + if ( $local && $local->getId() ) { |
71 | 72 | // An unattached local account; central authentication can't |
72 | 73 | // be used until this account has been transferred. |
73 | 74 | // $wgCentralAuthStrict will determine if local login is allowed. |
— | — | @@ -149,7 +150,7 @@ |
150 | 151 | function setPassword( $user, $password ) { |
151 | 152 | // Fixme: password changes should happen through central interface. |
152 | 153 | $central = CentralAuthUser::getInstance( $user ); |
153 | | - if( $central->isAttached() ) { |
| 154 | + if ( $central->isAttached() ) { |
154 | 155 | return $central->setPassword( $password ); |
155 | 156 | } else { |
156 | 157 | // Not attached, local password is set only |
— | — | @@ -194,11 +195,11 @@ |
195 | 196 | * @return bool |
196 | 197 | * @public |
197 | 198 | */ |
198 | | - function addUser( $user, $password, $email='', $realname='' ) { |
| 199 | + function addUser( $user, $password, $email = '', $realname = '' ) { |
199 | 200 | global $wgCentralAuthAutoNew; |
200 | | - if( $wgCentralAuthAutoNew ) { |
| 201 | + if ( $wgCentralAuthAutoNew ) { |
201 | 202 | $central = CentralAuthUser::getInstance( $user ); |
202 | | - if( !$central->exists() && !$central->listUnattached() ) { |
| 203 | + if ( !$central->exists() && !$central->listUnattached() ) { |
203 | 204 | // Username is unused; set up as a global account |
204 | 205 | // @fixme is this even vaguely reliable? pah |
205 | 206 | $central->register( $password, $email, $realname ); |
— | — | @@ -234,17 +235,17 @@ |
235 | 236 | * @param $user User object. |
236 | 237 | * @public |
237 | 238 | */ |
238 | | - function initUser( &$user, $autocreate=false ) { |
239 | | - if( $autocreate ) { |
| 239 | + function initUser( &$user, $autocreate = false ) { |
| 240 | + if ( $autocreate ) { |
240 | 241 | $central = CentralAuthUser::getInstance( $user ); |
241 | | - if( $central->exists() ) { |
| 242 | + if ( $central->exists() ) { |
242 | 243 | $central->attach( wfWikiID(), 'login' ); |
243 | 244 | $central->addLocalName( wfWikiID() ); |
244 | 245 | $this->updateUser( $user ); |
245 | 246 | } |
246 | 247 | } |
247 | 248 | } |
248 | | - |
| 249 | + |
249 | 250 | public function getUserInstance( User &$user ) { |
250 | 251 | return CentralAuthUser::getInstance( $user ); |
251 | 252 | } |
Index: trunk/extensions/CentralAuth/SpecialGlobalGroupMembership.php |
— | — | @@ -1,17 +1,17 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | /** |
5 | 4 | * |
6 | 5 | * Equivalent of Special:Userrights for global groups. |
7 | 6 | * @addtogroup extensions |
8 | 7 | */ |
9 | | - |
| 8 | + |
10 | 9 | class SpecialGlobalGroupMembership extends UserrightsPage { |
11 | 10 | var $mGlobalUser; |
| 11 | + |
12 | 12 | function SpecialGlobalGroupMembership() { |
13 | 13 | SpecialPage::SpecialPage( 'GlobalGroupMembership' ); |
14 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
15 | | - |
| 14 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
| 15 | + |
16 | 16 | global $wgUser; |
17 | 17 | $this->mGlobalUser = CentralAuthUser::getInstance( $wgUser ); |
18 | 18 | } |
— | — | @@ -20,25 +20,25 @@ |
21 | 21 | global $wgRequest; |
22 | 22 | $knownWikis = $this->mGlobalUser->listAttached(); |
23 | 23 | $title = $this->getTitle( $this->mTarget ); |
24 | | - return $title->getFullURL( 'wpKnownWiki='.urlencode( $knownWikis[0] ) ); |
| 24 | + return $title->getFullURL( 'wpKnownWiki=' . urlencode( $knownWikis[0] ) ); |
25 | 25 | } |
26 | | - |
| 26 | + |
27 | 27 | /** |
28 | 28 | * Output a form to allow searching for a user |
29 | 29 | */ |
30 | 30 | function switchForm() { |
31 | 31 | global $wgOut, $wgScript, $wgRequest; |
32 | | - |
| 32 | + |
33 | 33 | $knownwiki = $wgRequest->getVal( 'wpKnownWiki' ); |
34 | 34 | $knownwiki = $knownwiki ? $knownwiki : wfWikiId(); |
35 | | - |
| 35 | + |
36 | 36 | // Generate wiki selector |
37 | | - $selector = new XmlSelect('wpKnownWiki', 'wpKnownWiki', $knownwiki); |
38 | | - |
39 | | - foreach (CentralAuthUser::getWikiList() as $wiki) { |
| 37 | + $selector = new XmlSelect( 'wpKnownWiki', 'wpKnownWiki', $knownwiki ); |
| 38 | + |
| 39 | + foreach ( CentralAuthUser::getWikiList() as $wiki ) { |
40 | 40 | $selector->addOption( $wiki ); |
41 | 41 | } |
42 | | - |
| 42 | + |
43 | 43 | $wgOut->addHTML( |
44 | 44 | Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript, 'name' => 'uluser', 'id' => 'mw-userrights-form1' ) ) . |
45 | 45 | Xml::hidden( 'title', $this->getTitle() ) . |
— | — | @@ -52,56 +52,56 @@ |
53 | 53 | Xml::closeElement( 'form' ) . "\n" |
54 | 54 | ); |
55 | 55 | } |
56 | | - |
| 56 | + |
57 | 57 | function changeableGroups() { |
58 | 58 | global $wgUser; |
59 | | - |
60 | | - ## Should be a global user |
61 | | - if (!$this->mGlobalUser->exists() || !$this->mGlobalUser->isAttached()) { |
| 59 | + |
| 60 | + # # Should be a global user |
| 61 | + if ( !$this->mGlobalUser->exists() || !$this->mGlobalUser->isAttached() ) { |
62 | 62 | return array(); |
63 | 63 | } |
64 | | - |
| 64 | + |
65 | 65 | $allGroups = CentralAuthUser::availableGlobalGroups(); |
66 | | - |
67 | | - ## Permission MUST be gained from global rights. |
| 66 | + |
| 67 | + # # Permission MUST be gained from global rights. |
68 | 68 | if ( $this->mGlobalUser->hasGlobalPermission( 'globalgroupmembership' ) ) { |
69 | | - #specify addself and removeself as empty arrays -- bug 16098 |
| 69 | + # specify addself and removeself as empty arrays -- bug 16098 |
70 | 70 | return array( 'add' => $allGroups, 'remove' => $allGroups, 'add-self' => array(), 'remove-self' => array() ); |
71 | 71 | } else { |
72 | 72 | return array( 'add' => array(), 'remove' => array(), 'add-self' => array(), 'remove-self' => array() ); |
73 | 73 | } |
74 | 74 | } |
75 | | - |
| 75 | + |
76 | 76 | function fetchUser( $username ) { |
77 | 77 | global $wgUser, $wgRequest; |
78 | | - |
79 | | - $knownwiki = $wgRequest->getVal('wpKnownWiki'); |
80 | | - |
| 78 | + |
| 79 | + $knownwiki = $wgRequest->getVal( 'wpKnownWiki' ); |
| 80 | + |
81 | 81 | $user = CentralAuthGroupMembershipProxy::newFromName( $username ); |
82 | | - |
83 | | - if( !$user ) { |
| 82 | + |
| 83 | + if ( !$user ) { |
84 | 84 | return Status::newFatal( 'nosuchusershort', $username ); |
85 | | - } elseif (!$wgRequest->getCheck( 'saveusergroups' ) && !$user->attachedOn($knownwiki)) { |
| 85 | + } elseif ( !$wgRequest->getCheck( 'saveusergroups' ) && !$user->attachedOn( $knownwiki ) ) { |
86 | 86 | return Status::newFatal( 'centralauth-globalgroupmembership-badknownwiki', |
87 | 87 | $username, $knownwiki ); |
88 | 88 | } |
89 | | - |
| 89 | + |
90 | 90 | return Status::newGood( $user ); |
91 | 91 | } |
92 | | - |
| 92 | + |
93 | 93 | protected static function getAllGroups() { |
94 | 94 | return CentralAuthUser::availableGlobalGroups(); |
95 | 95 | } |
96 | | - |
| 96 | + |
97 | 97 | protected function showLogFragment( $user, $output ) { |
98 | | - $pageTitle = Title::makeTitleSafe( NS_USER, $user->getName()); |
| 98 | + $pageTitle = Title::makeTitleSafe( NS_USER, $user->getName() ); |
99 | 99 | $output->addHTML( Xml::element( 'h2', null, LogPage::logName( 'gblrights' ) . "\n" ) ); |
100 | 100 | LogEventsList::showLogExtract( $output, 'gblrights', $pageTitle->getPrefixedText() ); |
101 | 101 | } |
102 | | - |
| 102 | + |
103 | 103 | function addLogEntry( $user, $oldGroups, $newGroups, $reason ) { |
104 | 104 | global $wgRequest; |
105 | | - |
| 105 | + |
106 | 106 | $log = new LogPage( 'gblrights' ); |
107 | 107 | |
108 | 108 | $log->addEntry( 'usergroups', |
Index: trunk/extensions/CentralAuth/ApiQueryGlobalUserInfo.php |
— | — | @@ -1,5 +1,4 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | /** |
5 | 4 | * Created on Jan 30, 2010 |
6 | 5 | * |
— | — | @@ -30,13 +29,13 @@ |
31 | 30 | * @ingroup Extensions |
32 | 31 | */ |
33 | 32 | class ApiQueryGlobalUserInfo extends ApiQueryBase { |
34 | | - |
35 | 33 | public function __construct( $query, $moduleName ) { |
36 | 34 | parent::__construct( $query, $moduleName, 'gui' ); |
37 | 35 | } |
38 | 36 | |
39 | 37 | public function execute() { |
40 | 38 | global $wgUser; |
| 39 | + |
41 | 40 | $params = $this->extractRequestParams(); |
42 | 41 | $prop = array_flip( (array)$params['prop'] ); |
43 | 42 | if ( is_null( $params['user'] ) ) { |
— | — | @@ -46,7 +45,7 @@ |
47 | 46 | if ( !$user->exists() ) { |
48 | 47 | $this->dieUsageMsg( array( 'nosuchuser', $params['user'] ) ); |
49 | 48 | } |
50 | | - |
| 49 | + |
51 | 50 | // Add basic info |
52 | 51 | $result = $this->getResult(); |
53 | 52 | $data = array( |
— | — | @@ -61,7 +60,7 @@ |
62 | 61 | $data['hidden'] = ''; |
63 | 62 | } |
64 | 63 | $result->addValue( 'query', $this->getModuleName(), $data ); |
65 | | - |
| 64 | + |
66 | 65 | // Add requested info |
67 | 66 | if ( isset( $prop['groups'] ) ) { |
68 | 67 | $groups = $user->getGlobalGroups(); |
— | — | @@ -129,7 +128,8 @@ |
130 | 129 | public function getParamDescription() { |
131 | 130 | return array( |
132 | 131 | 'user' => 'User to get information about. Defaults to the current user', |
133 | | - 'prop' => array( 'Which properties to get:', |
| 132 | + 'prop' => array( |
| 133 | + 'Which properties to get:', |
134 | 134 | ' groups - Get a list of global groups this user belongs to', |
135 | 135 | ' merged - Get a list of merged accounts', |
136 | 136 | ' unattached - Get a list of unattached accounts' |
— | — | @@ -140,7 +140,7 @@ |
141 | 141 | public function getDescription() { |
142 | 142 | return 'Show information about a global user.'; |
143 | 143 | } |
144 | | - |
| 144 | + |
145 | 145 | public function getPossibleErrors() { |
146 | 146 | return array_merge( parent::getPossibleErrors(), array( |
147 | 147 | array( 'nosuchuser', 'user' ), |
Index: trunk/extensions/CentralAuth/migratePass0.php |
— | — | @@ -1,11 +1,10 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | // --> disable account creations, password changes |
5 | 4 | // pass 0: |
6 | 5 | // * generate 'globalnames' and 'localnames' entries for each user on each wiki |
7 | 6 | // --> enable |
8 | 7 | |
9 | | -require dirname(__FILE__) . '/../../maintenance/commandLine.inc'; |
| 8 | +require dirname( __FILE__ ) . '/../../maintenance/commandLine.inc'; |
10 | 9 | |
11 | 10 | /** |
12 | 11 | * Copy user data for this wiki into the localuser table |
— | — | @@ -23,15 +22,15 @@ |
24 | 23 | // on the central authentication server. |
25 | 24 | |
26 | 25 | $lastUser = $dbr->selectField( 'user', 'MAX(user_id)', '', __FUNCTION__ ); |
27 | | - for( $min = 0; $min <= $lastUser; $min += $chunkSize ) { |
| 26 | + for ( $min = 0; $min <= $lastUser; $min += $chunkSize ) { |
28 | 27 | $max = $min + $chunkSize; |
29 | 28 | $result = $dbr->select( 'user', |
30 | 29 | array( 'user_id', 'user_name' ), |
31 | 30 | "user_id BETWEEN $min AND $max", |
32 | 31 | __FUNCTION__ ); |
33 | 32 | |
34 | | - while( $row = $dbr->fetchObject( $result ) ) { |
35 | | - $users[intval($row->user_id)] = $row->user_name; |
| 33 | + while ( $row = $dbr->fetchObject( $result ) ) { |
| 34 | + $users[intval( $row->user_id )] = $row->user_name; |
36 | 35 | ++$migrated; |
37 | 36 | } |
38 | 37 | $dbr->freeResult( $result ); |
— | — | @@ -39,7 +38,7 @@ |
40 | 39 | CentralAuthUser::storeMigrationData( $wgDBname, $users ); |
41 | 40 | |
42 | 41 | $delta = microtime( true ) - $start; |
43 | | - $rate = ($delta == 0.0) ? 0.0 : $migrated / $delta; |
| 42 | + $rate = ( $delta == 0.0 ) ? 0.0 : $migrated / $delta; |
44 | 43 | printf( "%s %d (%0.1f%%) done in %0.1f secs (%0.3f accounts/sec).\n", |
45 | 44 | $wgDBname, |
46 | 45 | $migrated, |
Index: trunk/extensions/CentralAuth/central-auth.sql |
— | — | @@ -80,14 +80,14 @@ |
81 | 81 | -- Random key for password resets |
82 | 82 | gu_password_reset_key tinyblob, |
83 | 83 | gu_password_reset_expiration varchar(14) binary, |
84 | | - |
| 84 | + |
85 | 85 | -- Random key for crosswiki authentication tokens |
86 | 86 | gu_auth_token varbinary(32) NULL, |
87 | 87 | |
88 | 88 | primary key (gu_id), |
89 | 89 | unique key (gu_name), |
90 | 90 | key (gu_email), |
91 | | - |
| 91 | + |
92 | 92 | key gu_locked( gu_name(255), gu_locked ), |
93 | 93 | key gu_hidden( gu_name(255), gu_hidden(255) ) |
94 | 94 | ) /*$wgDBTableOptions*/; |
— | — | @@ -122,7 +122,7 @@ |
123 | 123 | CREATE TABLE global_user_groups ( |
124 | 124 | gug_user int(11) not null, |
125 | 125 | gug_group varchar(255) not null, |
126 | | - |
| 126 | + |
127 | 127 | PRIMARY KEY (gug_user,gug_group), |
128 | 128 | KEY (gug_user), |
129 | 129 | key (gug_group) |
— | — | @@ -132,7 +132,7 @@ |
133 | 133 | CREATE TABLE global_group_permissions ( |
134 | 134 | ggp_group varchar(255) not null, |
135 | 135 | ggp_permission varchar(255) not null, |
136 | | - |
| 136 | + |
137 | 137 | PRIMARY KEY (ggp_group, ggp_permission), |
138 | 138 | KEY (ggp_group), |
139 | 139 | KEY (ggp_permission) |
— | — | @@ -152,7 +152,7 @@ |
153 | 153 | -- Let's suppose that max length of db name is 31 (32 with ","), then we have space for |
154 | 154 | -- 2048 wikis. More than we need |
155 | 155 | ws_wikis blob not null, |
156 | | - |
| 156 | + |
157 | 157 | PRIMARY KEY ws_id (ws_id), |
158 | 158 | UNIQUE ws_name (ws_name) |
159 | 159 | ) /*$wgDBTableOptions*/; |
Index: trunk/extensions/CentralAuth/migratePass1.php |
— | — | @@ -1,11 +1,10 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | // pass 1: |
5 | 4 | // * generate 'globaluser' entries for each username |
6 | 5 | // * go through all usernames in 'globalnames' and for those |
7 | 6 | // that can be automatically migrated, go ahead and do it. |
8 | 7 | |
9 | | -require dirname(__FILE__) . '/../../maintenance/commandLine.inc'; |
| 8 | +require dirname( __FILE__ ) . '/../../maintenance/commandLine.inc'; |
10 | 9 | |
11 | 10 | function migratePassOne() { |
12 | 11 | $migrated = 0; |
— | — | @@ -19,13 +18,13 @@ |
20 | 19 | array( 'gn_name' ), |
21 | 20 | '', |
22 | 21 | __METHOD__ ); |
23 | | - while( $row = $dbBackground->fetchObject( $result ) ) { |
| 22 | + while ( $row = $dbBackground->fetchObject( $result ) ) { |
24 | 23 | $name = $row->gn_name; |
25 | 24 | $central = new CentralAuthUser( $name ); |
26 | | - if( $central->storeAndMigrate() ) { |
| 25 | + if ( $central->storeAndMigrate() ) { |
27 | 26 | $migrated++; |
28 | 27 | } |
29 | | - if( ++$total % $chunkSize == 0 ) { |
| 28 | + if ( ++$total % $chunkSize == 0 ) { |
30 | 29 | migratePassOneReport( $migrated, $total, $start ); |
31 | 30 | } |
32 | 31 | } |
Index: trunk/extensions/CentralAuth/evil-plans.txt |
— | — | @@ -248,4 +248,3 @@ |
249 | 249 | for approved users, and shift the permissions over from 'user' to 'private' |
250 | 250 | or whatever. Then add some handy way for local sysops to privatise people, |
251 | 251 | rather than the cumbersome 'account by email'. |
252 | | - |
Index: trunk/extensions/CentralAuth/SpecialAutoLogin.php |
— | — | @@ -1,6 +1,6 @@ |
2 | 2 | <?php |
3 | | -if (!defined('MEDIAWIKI')) { |
4 | | - die('CentralAuth'); |
| 3 | +if ( !defined( 'MEDIAWIKI' ) ) { |
| 4 | + die( 'CentralAuth' ); |
5 | 5 | } |
6 | 6 | |
7 | 7 | /** |
— | — | @@ -9,9 +9,8 @@ |
10 | 10 | * @addtogroup Extensions |
11 | 11 | */ |
12 | 12 | class SpecialAutoLogin extends UnlistedSpecialPage { |
13 | | - |
14 | 13 | function __construct() { |
15 | | - parent::__construct('AutoLogin'); |
| 14 | + parent::__construct( 'AutoLogin' ); |
16 | 15 | } |
17 | 16 | |
18 | 17 | function execute( $par ) { |
— | — | @@ -23,7 +22,7 @@ |
24 | 23 | # Don't cache error messages |
25 | 24 | $wgOut->enableClientCache( false ); |
26 | 25 | |
27 | | - if( strlen( $tempToken ) == 0 ) { |
| 26 | + if ( strlen( $tempToken ) == 0 ) { |
28 | 27 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
29 | 28 | $this->setHeaders(); |
30 | 29 | $wgOut->addWikiMsg( 'centralauth-autologin-desc' ); |
— | — | @@ -34,9 +33,9 @@ |
35 | 34 | $data = $wgMemc->get( $key ); |
36 | 35 | $wgMemc->delete( $key ); |
37 | 36 | |
38 | | - if( !$data ) { |
| 37 | + if ( !$data ) { |
39 | 38 | $msg = 'Token is invalid or has expired'; |
40 | | - wfDebug( __METHOD__.": $msg\n" ); |
| 39 | + wfDebug( __METHOD__ . ": $msg\n" ); |
41 | 40 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
42 | 41 | $this->setHeaders(); |
43 | 42 | $wgOut->addWikiText( $msg ); |
— | — | @@ -47,9 +46,9 @@ |
48 | 47 | $token = $data['token']; |
49 | 48 | $remember = $data['remember']; |
50 | 49 | |
51 | | - if( $data['wiki'] != wfWikiID() ) { |
| 50 | + if ( $data['wiki'] != wfWikiID() ) { |
52 | 51 | $msg = 'Bad token (wrong wiki)'; |
53 | | - wfDebug( __METHOD__.": $msg\n" ); |
| 52 | + wfDebug( __METHOD__ . ": $msg\n" ); |
54 | 53 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
55 | 54 | $this->setHeaders(); |
56 | 55 | $wgOut->addWikiText( $msg ); |
— | — | @@ -59,9 +58,9 @@ |
60 | 59 | $centralUser = new CentralAuthUser( $userName ); |
61 | 60 | $loginResult = $centralUser->authenticateWithToken( $token ); |
62 | 61 | |
63 | | - if( $loginResult != 'ok' ) { |
| 62 | + if ( $loginResult != 'ok' ) { |
64 | 63 | $msg = "Bad token: $loginResult"; |
65 | | - wfDebug( __METHOD__.": $msg\n" ); |
| 64 | + wfDebug( __METHOD__ . ": $msg\n" ); |
66 | 65 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
67 | 66 | $this->setHeaders(); |
68 | 67 | $wgOut->addWikiText( $msg ); |
— | — | @@ -82,10 +81,10 @@ |
83 | 82 | header( 'Content-Type: image/png' ); |
84 | 83 | |
85 | 84 | global $wgCentralAuthLoginIcon; |
86 | | - if( $wgCentralAuthLoginIcon ) { |
| 85 | + if ( $wgCentralAuthLoginIcon ) { |
87 | 86 | readfile( $wgCentralAuthLoginIcon ); |
88 | 87 | } else { |
89 | | - readfile( dirname(__FILE__).'/1x1.png' ); |
| 88 | + readfile( dirname( __FILE__ ) . '/1x1.png' ); |
90 | 89 | } |
91 | 90 | } |
92 | 91 | } |
Index: trunk/extensions/CentralAuth/SpecialWikiSets.php |
— | — | @@ -14,7 +14,7 @@ |
15 | 15 | |
16 | 16 | class SpecialWikiSets extends SpecialPage { |
17 | 17 | var $mCanEdit; |
18 | | - |
| 18 | + |
19 | 19 | function __construct() { |
20 | 20 | parent::__construct( 'WikiSets' ); |
21 | 21 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
— | — | @@ -31,10 +31,10 @@ |
32 | 32 | |
33 | 33 | $this->setHeaders(); |
34 | 34 | |
35 | | - if( strpos( $subpage, 'delete/' ) === 0 && $this->mCanEdit ) { |
| 35 | + if ( strpos( $subpage, 'delete/' ) === 0 && $this->mCanEdit ) { |
36 | 36 | $subpage = substr( $subpage, 7 ); // Remove delete/ part |
37 | | - if( is_numeric( $subpage ) ) { |
38 | | - if( $wgUser->matchEditToken( $wgRequest->getVal( 'wpEditToken' ) ) ) |
| 37 | + if ( is_numeric( $subpage ) ) { |
| 38 | + if ( $wgUser->matchEditToken( $wgRequest->getVal( 'wpEditToken' ) ) ) |
39 | 39 | $this->doDelete( $subpage ); |
40 | 40 | else |
41 | 41 | $this->buildDeleteView( $subpage ); |
— | — | @@ -42,9 +42,9 @@ |
43 | 43 | $this->buildMainView(); |
44 | 44 | } |
45 | 45 | } else { |
46 | | - if( $subpage && !is_numeric( $subpage ) ) { |
| 46 | + if ( $subpage && !is_numeric( $subpage ) ) { |
47 | 47 | $set = WikiSet::newFromName( $subpage ); |
48 | | - if( $set ) { |
| 48 | + if ( $set ) { |
49 | 49 | $subpage = $set->getID(); |
50 | 50 | } else { |
51 | 51 | $wgOut->setPageTitle( wfMsg( 'error' ) ); |
— | — | @@ -54,9 +54,9 @@ |
55 | 55 | } |
56 | 56 | } |
57 | 57 | |
58 | | - if( ( $subpage || $subpage === '0' ) && $this->mCanEdit && $wgUser->matchEditToken( $wgRequest->getVal( 'wpEditToken' ) ) ) { |
| 58 | + if ( ( $subpage || $subpage === '0' ) && $this->mCanEdit && $wgUser->matchEditToken( $wgRequest->getVal( 'wpEditToken' ) ) ) { |
59 | 59 | $this->doSubmit( $subpage ); |
60 | | - } else if( ( $subpage || $subpage === '0' ) && is_numeric( $subpage ) ) { |
| 60 | + } else if ( ( $subpage || $subpage === '0' ) && is_numeric( $subpage ) ) { |
61 | 61 | $this->buildSetView( $subpage ); |
62 | 62 | } else { |
63 | 63 | $this->buildMainView(); |
— | — | @@ -71,18 +71,18 @@ |
72 | 72 | $msgPostfix = $this->mCanEdit ? 'rw' : 'ro'; |
73 | 73 | $legend = wfMsg( "centralauth-editset-legend-{$msgPostfix}" ); |
74 | 74 | $wgOut->addHTML( "<fieldset><legend>{$legend}</legend>" ); |
75 | | - if( $msg ) |
| 75 | + if ( $msg ) |
76 | 76 | $wgOut->addHTML( $msg ); |
77 | 77 | $wgOut->addWikiMsg( "centralauth-editset-intro-{$msgPostfix}" ); |
78 | 78 | $wgOut->addHTML( '<ul>' ); |
79 | 79 | |
80 | 80 | $sets = WikiSet::getAllWikiSets(); |
81 | | - foreach( $sets as $set ) { |
| 81 | + foreach ( $sets as $set ) { |
82 | 82 | $text = wfMsgExt( "centralauth-editset-item-{$msgPostfix}", array( 'parseinline' ), $set->getName(), $set->getID() ); |
83 | 83 | $wgOut->addHTML( "<li>{$text}</li>" ); |
84 | 84 | } |
85 | 85 | |
86 | | - if( $this->mCanEdit ) { |
| 86 | + if ( $this->mCanEdit ) { |
87 | 87 | $target = SpecialPage::getTitleFor( 'WikiSets', '0' ); |
88 | 88 | $newlink = $sk->makeLinkObj( $target, wfMsgHtml( 'centralauth-editset-new' ) ); |
89 | 89 | $wgOut->addHTML( "<li>{$newlink}</li>" ); |
— | — | @@ -97,41 +97,44 @@ |
98 | 98 | $wgOut->setSubtitle( wfMsgExt( 'centralauth-editset-subtitle', 'parseinline' ) ); |
99 | 99 | |
100 | 100 | $set = $subpage ? WikiSet::newFromID( $subpage ) : null; |
101 | | - if( !$name ) $name = $set ? $set->getName() : ''; |
102 | | - if( !$type ) $type = $set ? $set->getType() : WikiSet::OPTIN; |
103 | | - if( !$wikis ) $wikis = implode( "\n", $set ? $set->getWikisRaw() : array() ); |
| 101 | + if ( !$name ) $name = $set ? $set->getName() : ''; |
| 102 | + if ( !$type ) $type = $set ? $set->getType() : WikiSet::OPTIN; |
| 103 | + if ( !$wikis ) $wikis = implode( "\n", $set ? $set->getWikisRaw() : array() ); |
104 | 104 | else $wikis = implode( "\n", $wikis ); |
105 | 105 | $url = SpecialPage::getTitleFor( 'WikiSets', $subpage )->getLocalUrl(); |
106 | | - if( $this->mCanEdit ) |
107 | | - $legend = wfMsgHtml( 'centralauth-editset-legend-' . ($set ? 'edit' : 'new'), $name ); |
108 | | - else |
| 106 | + if ( $this->mCanEdit ) { |
| 107 | + $legend = wfMsgHtml( 'centralauth-editset-legend-' . ( $set ? 'edit' : 'new' ), $name ); |
| 108 | + } else { |
109 | 109 | $legend = wfMsgHtml( 'centralauth-editset-legend-view', $name ); |
| 110 | + } |
110 | 111 | |
111 | 112 | $wgOut->addHTML( "<fieldset><legend>{$legend}</legend>" ); |
112 | 113 | |
113 | | - if( $set ) { |
| 114 | + if ( $set ) { |
114 | 115 | $groups = $set->getRestrictedGroups(); |
115 | 116 | if ( $groups ) { |
116 | 117 | $usage = "<ul>\n"; |
117 | | - foreach( $groups as $group ) |
118 | | - $usage .= "<li>" . wfMsgExt( 'centralauth-editset-grouplink', array('parseinline'), $group ) . "</li>\n"; |
| 118 | + foreach ( $groups as $group ) |
| 119 | + $usage .= "<li>" . wfMsgExt( 'centralauth-editset-grouplink', array( 'parseinline' ), $group ) . "</li>\n"; |
119 | 120 | $usage .= "</ul>"; |
120 | 121 | } else { |
121 | | - $usage = wfMsgWikiHtml('centralauth-editset-nouse'); |
| 122 | + $usage = wfMsgWikiHtml( 'centralauth-editset-nouse' ); |
122 | 123 | } |
123 | 124 | } else { |
124 | 125 | $usage = ''; |
125 | 126 | } |
126 | 127 | |
127 | | - if( $this->mCanEdit ) { |
128 | | - if( $error ) |
| 128 | + if ( $this->mCanEdit ) { |
| 129 | + if ( $error ) { |
129 | 130 | $wgOut->addHTML( "<strong class='error'>{$error}</strong>" ); |
| 131 | + } |
130 | 132 | $wgOut->addHTML( "<form action='{$url}' method='post'>" ); |
131 | 133 | |
132 | 134 | $form = array(); |
133 | 135 | $form['centralauth-editset-name'] = Xml::input( 'wpName', false, $name ); |
134 | | - if( $usage ) |
| 136 | + if ( $usage ) { |
135 | 137 | $form['centralauth-editset-usage'] = $usage; |
| 138 | + } |
136 | 139 | $form['centralauth-editset-type'] = $this->buildTypeSelector( 'wpType', $type ); |
137 | 140 | $form['centralauth-editset-wikis'] = Xml::textarea( 'wpWikis', $wikis ); |
138 | 141 | $form['centralauth-editset-reason'] = Xml::input( 'wpReason', false, $reason ); |
— | — | @@ -153,16 +156,18 @@ |
154 | 157 | |
155 | 158 | function buildTypeSelector( $name, $value ) { |
156 | 159 | $select = new XmlSelect( $name, 'set-type', $value ); |
157 | | - foreach( array( WikiSet::OPTIN, WikiSet::OPTOUT ) as $type ) |
| 160 | + foreach ( array( WikiSet::OPTIN, WikiSet::OPTOUT ) as $type ) { |
158 | 161 | $select->addOption( wfMsg( "centralauth-editset-{$type}" ), $type ); |
| 162 | + } |
159 | 163 | return $select->getHTML(); |
160 | 164 | } |
161 | 165 | |
162 | 166 | function buildWikiList( $list ) { |
163 | 167 | sort( $list ); |
164 | 168 | $html = '<ul>'; |
165 | | - foreach( $list as $wiki ) |
| 169 | + foreach ( $list as $wiki ) { |
166 | 170 | $html .= "<li>{$wiki}</li>"; |
| 171 | + } |
167 | 172 | $html .= '</ul>'; |
168 | 173 | return $html; |
169 | 174 | } |
— | — | @@ -170,9 +175,9 @@ |
171 | 176 | function buildDeleteView( $subpage ) { |
172 | 177 | global $wgOut, $wgUser; |
173 | 178 | $wgOut->setSubtitle( wfMsgExt( 'centralauth-editset-subtitle', 'parseinline' ) ); |
174 | | - |
| 179 | + |
175 | 180 | $set = WikiSet::newFromID( $subpage ); |
176 | | - if( !$set ) { |
| 181 | + if ( !$set ) { |
177 | 182 | $this->buildMainView( '<strong class="error">' . wfMsgHtml( 'centralauth-editset-notfound', $subpage ) . '</strong>' ); |
178 | 183 | return; |
179 | 184 | } |
— | — | @@ -196,34 +201,36 @@ |
197 | 202 | $reason = $wgRequest->getVal( 'wpReason' ); |
198 | 203 | $set = WikiSet::newFromId( $id ); |
199 | 204 | |
200 | | - if( !Title::newFromText( $name ) ) { |
| 205 | + if ( !Title::newFromText( $name ) ) { |
201 | 206 | $this->buildSetView( $id, wfMsgHtml( 'centralauth-editset-badname' ), $name, $type, $wikis, $reason ); |
202 | 207 | return; |
203 | 208 | } |
204 | | - if( (!$id || $set->getName() != $name ) && WikiSet::newFromName( $name ) ) { |
| 209 | + if ( ( !$id || $set->getName() != $name ) && WikiSet::newFromName( $name ) ) { |
205 | 210 | $this->buildSetView( $id, wfMsgHtml( 'centralauth-editset-setexists' ), $name, $type, $wikis, $reason ); |
206 | 211 | return; |
207 | 212 | } |
208 | | - if( !in_array( $type, array( WikiSet::OPTIN, WikiSet::OPTOUT ) ) ) { |
| 213 | + if ( !in_array( $type, array( WikiSet::OPTIN, WikiSet::OPTOUT ) ) ) { |
209 | 214 | $this->buildSetView( $id, wfMsgHtml( 'centralauth-editset-badtype' ), $name, $type, $wikis, $reason ); |
210 | 215 | return; |
211 | 216 | } |
212 | | - if( !$wikis ) { |
| 217 | + if ( !$wikis ) { |
213 | 218 | $this->buildSetView( $id, wfMsgHtml( 'centralauth-editset-nowikis' ), $name, $type, $wikis, $reason ); |
214 | 219 | return; |
215 | 220 | } |
216 | 221 | $badwikis = array(); |
217 | 222 | $allwikis = CentralAuthUser::getWikiList(); |
218 | | - foreach( $wikis as $wiki ) |
219 | | - if( !in_array( $wiki, $allwikis ) ) |
| 223 | + foreach ( $wikis as $wiki ) { |
| 224 | + if ( !in_array( $wiki, $allwikis ) ) { |
220 | 225 | $badwikis[] = $wiki; |
221 | | - if( $badwikis ) { |
222 | | - $this->buildSetView( $id, wfMsgExt( 'centralauth-editset-badwikis', array( 'escapenoentities', 'parsemag' ), |
| 226 | + } |
| 227 | + } |
| 228 | + if ( $badwikis ) { |
| 229 | + $this->buildSetView( $id, wfMsgExt( 'centralauth-editset-badwikis', array( 'escapenoentities', 'parsemag' ), |
223 | 230 | implode( ', ', $badwikis ), count( $badwikis ) ), $name, $type, $wikis, $reason ); |
224 | 231 | return; |
225 | 232 | } |
226 | 233 | |
227 | | - if( $set ) { |
| 234 | + if ( $set ) { |
228 | 235 | $oldname = $set->getName(); |
229 | 236 | $oldtype = $set->getType(); |
230 | 237 | $oldwikis = $set->getWikisRaw(); |
— | — | @@ -239,41 +246,43 @@ |
240 | 247 | // Now logging |
241 | 248 | $log = new LogPage( 'gblrights' ); |
242 | 249 | $title = SpecialPage::getTitleFor( 'WikiSets', $set->getID() ); |
243 | | - if( !$oldname ) { |
| 250 | + if ( !$oldname ) { |
244 | 251 | // New set |
245 | 252 | $log->addEntry( 'newset', $title, $reason, array( $name, $type, implode( ', ', $wikis ) ) ); |
246 | 253 | } else { |
247 | | - if( $oldname != $name ) |
| 254 | + if ( $oldname != $name ) { |
248 | 255 | $log->addEntry( 'setrename', $title, $reason, array( $name, $oldname ) ); |
249 | | - if( $oldtype != $type ) |
| 256 | + } |
| 257 | + if ( $oldtype != $type ) { |
250 | 258 | $log->addEntry( 'setnewtype', $title, $reason, array( $name, $oldtype, $type ) ); |
| 259 | + } |
251 | 260 | $added = implode( ', ', array_diff( $wikis, $oldwikis ) ); |
252 | 261 | $removed = implode( ', ', array_diff( $oldwikis, $wikis ) ); |
253 | | - if( $added || $removed ) { |
| 262 | + if ( $added || $removed ) { |
254 | 263 | $log->addEntry( 'setchange', $title, $reason, array( $name, $added, $removed ) ); |
255 | 264 | } |
256 | 265 | } |
257 | | - |
258 | | - global $wgUser,$wgOut; |
| 266 | + |
| 267 | + global $wgUser, $wgOut; |
259 | 268 | $sk = $wgUser->getSkin(); |
260 | 269 | $returnLink = $sk->makeKnownLinkObj( $this->getTitle(), wfMsg( 'centralauth-editset-return' ) ); |
261 | 270 | |
262 | | - $wgOut->addHTML( '<strong class="success">' . wfMsgHtml( 'centralauth-editset-success' ) . '</strong> <p>'.$returnLink.'</p>' ); |
| 271 | + $wgOut->addHTML( '<strong class="success">' . wfMsgHtml( 'centralauth-editset-success' ) . '</strong> <p>' . $returnLink . '</p>' ); |
263 | 272 | } |
264 | | - |
| 273 | + |
265 | 274 | function doDelete( $set ) { |
266 | 275 | global $wgRequest, $wgContLang; |
267 | | - |
| 276 | + |
268 | 277 | $set = WikiSet::newFromID( $set ); |
269 | | - if( !$set ) { |
| 278 | + if ( !$set ) { |
270 | 279 | $this->buildMainView( '<strong class="error">' . wfMsgHtml( 'centralauth-editset-notfound', $subpage ) . '</strong>' ); |
271 | 280 | return; |
272 | 281 | } |
273 | | - |
| 282 | + |
274 | 283 | $reason = $wgRequest->getVal( 'wpReason' ); |
275 | 284 | $name = $set->getName(); |
276 | 285 | $set->delete(); |
277 | | - |
| 286 | + |
278 | 287 | $title = SpecialPage::getTitleFor( 'WikiSets', $set->getID() ); |
279 | 288 | $log = new LogPage( 'gblrights' ); |
280 | 289 | $log->addEntry( 'deleteset', $title, $reason, array( $name ) ); |
Index: trunk/extensions/CentralAuth/migrateStewards.php |
— | — | @@ -1,11 +1,11 @@ |
2 | 2 | <?php |
3 | 3 | |
4 | | -require dirname(__FILE__) . '/../../maintenance/commandLine.inc'; |
| 4 | +require dirname( __FILE__ ) . '/../../maintenance/commandLine.inc'; |
5 | 5 | |
6 | 6 | echo "Populating global groups table with stewards...\n"; |
7 | 7 | |
8 | 8 | // Fetch local stewards |
9 | | -$dbl = wfGetDB( DB_SLAVE ); //Get local database |
| 9 | +$dbl = wfGetDB( DB_SLAVE ); // Get local database |
10 | 10 | $result = $dbl->select( |
11 | 11 | array( 'user', 'user_groups' ), |
12 | 12 | array( 'user_name' ), |
— | — | @@ -16,7 +16,7 @@ |
17 | 17 | 'migrateStewards.php' |
18 | 18 | ); |
19 | 19 | $localStewards = array(); |
20 | | -while( $row = $dbl->fetchObject( $result ) ) { |
| 20 | +while ( $row = $dbl->fetchObject( $result ) ) { |
21 | 21 | $localStewards[] = $row->user_name; |
22 | 22 | } |
23 | 23 | |
— | — | @@ -33,19 +33,19 @@ |
34 | 34 | ), |
35 | 35 | 'migrateStewards.php' |
36 | 36 | ); |
37 | | -while( $row = $dbl->fetchObject( $result ) ) { |
| 37 | +while ( $row = $dbl->fetchObject( $result ) ) { |
38 | 38 | $globalStewards[$row->gu_name] = $row->gu_id; |
39 | 39 | } |
40 | 40 | |
41 | 41 | echo "Fetched " . count( $localStewards ) . " SULed stewards... Adding them in group\n"; |
42 | | -foreach( $globalStewards as $user => $id ) { |
| 42 | +foreach ( $globalStewards as $user => $id ) { |
43 | 43 | $dbg->insert( 'global_user_groups', |
44 | 44 | array( |
45 | 45 | 'gug_user' => $id, |
46 | 46 | 'gug_group' => 'steward' ), |
47 | 47 | 'migrateStewards.php' ); |
48 | 48 | echo "Added {$user}\n"; |
49 | | - |
| 49 | + |
50 | 50 | $u = new CentralAuthUser( $user ); |
51 | 51 | $u->quickInvalidateCache(); // Don't bother regenerating the steward's cache. |
52 | 52 | } |
Index: trunk/extensions/CentralAuth/CentralAuthGroupMembershipProxy.php |
— | — | @@ -1,6 +1,4 @@ |
2 | 2 | <?php |
3 | | - |
4 | | - |
5 | 3 | /** |
6 | 4 | * Cut-down copy of User interface for local-interwiki-database |
7 | 5 | * user rights manipulation. |
— | — | @@ -13,7 +11,7 @@ |
14 | 12 | |
15 | 13 | public static function whoIs( $wikiID, $id ) { |
16 | 14 | $user = self::newFromId( $wikiID, $id ); |
17 | | - if( $user ) { |
| 15 | + if ( $user ) { |
18 | 16 | return $user->name; |
19 | 17 | } else { |
20 | 18 | return false; |
Index: trunk/extensions/CentralAuth/CentralAuthUserArray.php |
— | — | @@ -17,7 +17,7 @@ |
18 | 18 | } |
19 | 19 | |
20 | 20 | /** |
21 | | - * Load global user data |
| 21 | + * Load global user data |
22 | 22 | */ |
23 | 23 | $names = array(); |
24 | 24 | foreach ( $res as $row ) { |
— | — | @@ -27,7 +27,7 @@ |
28 | 28 | |
29 | 29 | $dbr = CentralAuthUser::getCentralSlaveDB(); |
30 | 30 | $caRes = $dbr->select( array( 'localuser', 'globaluser' ), '*', |
31 | | - array( |
| 31 | + array( |
32 | 32 | 'gu_name' => $names, |
33 | 33 | 'lu_name=gu_name', |
34 | 34 | 'lu_wiki' => wfWikiID() |
— | — | @@ -36,7 +36,7 @@ |
37 | 37 | foreach ( $caRes as $row ) { |
38 | 38 | $this->globalData[$row->gu_name] = $row; |
39 | 39 | } |
40 | | - wfDebug( __METHOD__.': got user data for ' . implode( ', ', |
| 40 | + wfDebug( __METHOD__ . ': got user data for ' . implode( ', ', |
41 | 41 | array_keys( $this->globalData ) ) . "\n" ); |
42 | 42 | } |
43 | 43 | |
— | — | @@ -49,4 +49,3 @@ |
50 | 50 | } |
51 | 51 | } |
52 | 52 | } |
53 | | - |
Index: trunk/extensions/CentralAuth/CentralAuthUser.php |
— | — | @@ -1,5 +1,4 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | /* |
5 | 4 | |
6 | 5 | likely construction types... |
— | — | @@ -12,7 +11,6 @@ |
13 | 12 | */ |
14 | 13 | |
15 | 14 | class CentralAuthUser extends AuthPluginUser { |
16 | | - |
17 | 15 | /** |
18 | 16 | * The username of the current user. |
19 | 17 | */ |
— | — | @@ -20,7 +18,7 @@ |
21 | 19 | /*private*/ var $mStateDirty = false; |
22 | 20 | /*private*/ var $mVersion = 4; |
23 | 21 | /*private*/ var $mDelayInvalidation = 0; |
24 | | - |
| 22 | + |
25 | 23 | static $mCacheVars = array( |
26 | 24 | 'mGlobalId', |
27 | 25 | 'mSalt', |
— | — | @@ -35,7 +33,7 @@ |
36 | 34 | 'mRights', |
37 | 35 | 'mHomeWiki', |
38 | 36 | |
39 | | - # Store the string list instead of the array, to save memory, and |
| 37 | + # Store the string list instead of the array, to save memory, and |
40 | 38 | # avoid unserialize() overhead |
41 | 39 | 'mAttachedList', |
42 | 40 | |
— | — | @@ -99,10 +97,10 @@ |
100 | 98 | unset( $this->mAttachedList ); |
101 | 99 | unset( $this->mHomeWiki ); |
102 | 100 | } |
103 | | - |
| 101 | + |
104 | 102 | /** |
105 | 103 | * Load up state information, but don't use the cache |
106 | | - */ |
| 104 | + */ |
107 | 105 | protected function loadStateNoCache() { |
108 | 106 | $this->loadState( true ); |
109 | 107 | } |
— | — | @@ -125,9 +123,9 @@ |
126 | 124 | wfProfileOut( __METHOD__ ); |
127 | 125 | return; |
128 | 126 | } |
129 | | - |
| 127 | + |
130 | 128 | wfDebugLog( 'CentralAuth', "Loading state for global user {$this->mName} from DB" ); |
131 | | - |
| 129 | + |
132 | 130 | // Get the master. We want to make sure we've got up to date information |
133 | 131 | // since we're caching it. |
134 | 132 | $dbr = self::getCentralDB(); |
— | — | @@ -144,12 +142,12 @@ |
145 | 143 | $result = $dbr->safeQuery( $sql, wfWikiID(), $this->mName ); |
146 | 144 | $row = $dbr->fetchObject( $result ); |
147 | 145 | $dbr->freeResult( $result ); |
148 | | - |
| 146 | + |
149 | 147 | $this->loadFromRow( $row, true ); |
150 | 148 | $this->saveToCache(); |
151 | 149 | wfProfileOut( __METHOD__ ); |
152 | 150 | } |
153 | | - |
| 151 | + |
154 | 152 | /** |
155 | 153 | * Load user groups and rights from the database. |
156 | 154 | */ |
— | — | @@ -223,7 +221,7 @@ |
224 | 222 | $this->mHidden = ''; |
225 | 223 | } |
226 | 224 | } |
227 | | - |
| 225 | + |
228 | 226 | /** |
229 | 227 | * Load data from memcached |
230 | 228 | */ |
— | — | @@ -234,7 +232,7 @@ |
235 | 233 | $cache = $wgMemc->get( $this->getCacheKey() ); |
236 | 234 | $fromMaster = true; |
237 | 235 | } |
238 | | - |
| 236 | + |
239 | 237 | if ( !is_array( $cache ) || $cache['mVersion'] < $this->mVersion ) { |
240 | 238 | // Out of date cache. |
241 | 239 | wfDebugLog( 'CentralAuth', "Global User: cache miss for {$this->mName}, " . |
— | — | @@ -242,14 +240,14 @@ |
243 | 241 | wfProfileOut( __METHOD__ ); |
244 | 242 | return false; |
245 | 243 | } |
246 | | - |
| 244 | + |
247 | 245 | $this->loadFromCacheObject( $cache, $fromMaster ); |
248 | | - |
| 246 | + |
249 | 247 | wfProfileOut( __METHOD__ ); |
250 | | - |
| 248 | + |
251 | 249 | return true; |
252 | 250 | } |
253 | | - |
| 251 | + |
254 | 252 | /** |
255 | 253 | * Load user state from a cached array. |
256 | 254 | */ |
— | — | @@ -258,13 +256,13 @@ |
259 | 257 | foreach ( self::$mCacheVars as $var ) { |
260 | 258 | $this->$var = $object[$var]; |
261 | 259 | } |
262 | | - |
| 260 | + |
263 | 261 | $this->loadAttached(); |
264 | | - |
| 262 | + |
265 | 263 | $this->mIsAttached = $this->exists() && in_array( wfWikiID(), $this->mAttachedArray ); |
266 | 264 | $this->mFromMaster = $fromMaster; |
267 | 265 | } |
268 | | - |
| 266 | + |
269 | 267 | /** |
270 | 268 | * Get the object data as an array ready for caching |
271 | 269 | * @return Object to cache. |
— | — | @@ -273,7 +271,7 @@ |
274 | 272 | $this->loadState(); |
275 | 273 | $this->loadAttached(); |
276 | 274 | $this->loadGroups(); |
277 | | - |
| 275 | + |
278 | 276 | $obj = array(); |
279 | 277 | foreach ( self::$mCacheVars as $var ) { |
280 | 278 | if ( isset( $this->$var ) ) { |
— | — | @@ -282,10 +280,10 @@ |
283 | 281 | $obj[$var] = null; |
284 | 282 | } |
285 | 283 | } |
286 | | - |
| 284 | + |
287 | 285 | return $obj; |
288 | 286 | } |
289 | | - |
| 287 | + |
290 | 288 | /** |
291 | 289 | * Save cachable data to memcached. |
292 | 290 | */ |
— | — | @@ -309,14 +307,14 @@ |
310 | 308 | $this->loadState(); |
311 | 309 | return $this->mGlobalId; |
312 | 310 | } |
313 | | - |
| 311 | + |
314 | 312 | /** |
315 | 313 | * Generate a valid memcached key for caching the object's data. |
316 | 314 | */ |
317 | 315 | protected function getCacheKey() { |
318 | 316 | return "centralauth-user-" . md5( $this->mName ); |
319 | 317 | } |
320 | | - |
| 318 | + |
321 | 319 | /** |
322 | 320 | * Return the global account's name, whether it exists or not. |
323 | 321 | */ |
— | — | @@ -331,7 +329,7 @@ |
332 | 330 | $this->loadState(); |
333 | 331 | return $this->mIsAttached; |
334 | 332 | } |
335 | | - |
| 333 | + |
336 | 334 | /** |
337 | 335 | * Return the password salt and hash. |
338 | 336 | * @return array( salt, hash ) |
— | — | @@ -340,13 +338,13 @@ |
341 | 339 | $this->loadState(); |
342 | 340 | return array( $this->mSalt, $this->mPassword ); |
343 | 341 | } |
344 | | - |
| 342 | + |
345 | 343 | /** |
346 | 344 | * Return the global-login token for this account. |
347 | 345 | */ |
348 | 346 | public function getAuthToken() { |
349 | 347 | $this->loadState(); |
350 | | - |
| 348 | + |
351 | 349 | if ( !isset( $this->mAuthToken ) || !$this->mAuthToken ) { |
352 | 350 | $this->resetAuthToken(); |
353 | 351 | } |
— | — | @@ -378,7 +376,7 @@ |
379 | 377 | /** |
380 | 378 | * Returns whether user name should not |
381 | 379 | * be shown in public lists. |
382 | | - * @return bool |
| 380 | + * @return bool |
383 | 381 | */ |
384 | 382 | public function isHidden() { |
385 | 383 | $this->loadState(); |
— | — | @@ -462,7 +460,7 @@ |
463 | 461 | wfDebugLog( 'CentralAuth', |
464 | 462 | "registration failed for global account '$this->mName'" ); |
465 | 463 | } |
466 | | - |
| 464 | + |
467 | 465 | // Kill any cache entries saying we don't exist |
468 | 466 | $this->invalidateCache(); |
469 | 467 | return $ok; |
— | — | @@ -655,7 +653,7 @@ |
656 | 654 | * @param array &$unattached on success, list of wikis which won't be auto-attached |
657 | 655 | * @param array &$methods on success, associative array of each wiki's attachment method |
658 | 656 | * @param array &$blocked true if the home wiki is blocked |
659 | | - * |
| 657 | + * |
660 | 658 | * @return Status object |
661 | 659 | */ |
662 | 660 | function migrationDryRun( $passwords, &$home, &$attached, &$unattached, &$methods ) { |
— | — | @@ -758,14 +756,14 @@ |
759 | 757 | "Full automatic migration for '$this->mName'" ); |
760 | 758 | } |
761 | 759 | } |
762 | | - |
| 760 | + |
763 | 761 | // Don't purge the cache 50 times. |
764 | 762 | $this->startTransaction(); |
765 | 763 | |
766 | 764 | foreach ( $attach as $wiki => $method ) { |
767 | 765 | $this->attach( $wiki, $method ); |
768 | 766 | } |
769 | | - |
| 767 | + |
770 | 768 | $this->endTransaction(); |
771 | 769 | |
772 | 770 | return count( $attach ) == count( $migrationSet ); |
— | — | @@ -811,7 +809,7 @@ |
812 | 810 | $remaining[] = $wiki; |
813 | 811 | } |
814 | 812 | } |
815 | | - |
| 813 | + |
816 | 814 | $this->endTransaction(); |
817 | 815 | |
818 | 816 | if ( count( $remaining ) == 0 ) { |
— | — | @@ -866,7 +864,7 @@ |
867 | 865 | $status->error( 'centralauth-invalid-wiki', $wikiName ); |
868 | 866 | $status->failCount++; |
869 | 867 | } |
870 | | - |
| 868 | + |
871 | 869 | $invalidCount = count( $list ) - count( $valid ); |
872 | 870 | $missingCount = 0; |
873 | 871 | $dbcw = self::getCentralDB(); |
— | — | @@ -906,7 +904,7 @@ |
907 | 905 | if ( in_array( wfWikiID(), $valid ) ) { |
908 | 906 | $this->resetState(); |
909 | 907 | } |
910 | | - |
| 908 | + |
911 | 909 | $this->invalidateCache(); |
912 | 910 | |
913 | 911 | return $status; |
— | — | @@ -950,9 +948,9 @@ |
951 | 949 | # Delete the localuser rows |
952 | 950 | $centralDB->delete( 'localuser', array( 'lu_name' => $this->mName ), __METHOD__ ); |
953 | 951 | $centralDB->commit(); |
954 | | - |
| 952 | + |
955 | 953 | $this->invalidateCache(); |
956 | | - |
| 954 | + |
957 | 955 | return Status::newGood(); |
958 | 956 | } |
959 | 957 | |
— | — | @@ -969,9 +967,9 @@ |
970 | 968 | return Status::newFatal( 'centralauth-admin-lock-nonexistent', $this->mName ); |
971 | 969 | } |
972 | 970 | $dbw->commit(); |
973 | | - |
| 971 | + |
974 | 972 | $this->invalidateCache(); |
975 | | - |
| 973 | + |
976 | 974 | return Status::newGood(); |
977 | 975 | } |
978 | 976 | |
— | — | @@ -988,9 +986,9 @@ |
989 | 987 | return Status::newFatal( 'centralauth-admin-unlock-nonexistent', $this->mName ); |
990 | 988 | } |
991 | 989 | $dbw->commit(); |
992 | | - |
| 990 | + |
993 | 991 | $this->invalidateCache(); |
994 | | - |
| 992 | + |
995 | 993 | return Status::newGood(); |
996 | 994 | } |
997 | 995 | |
— | — | @@ -1089,22 +1087,22 @@ |
1090 | 1088 | array( $by, $reason ), true, $lang ); |
1091 | 1089 | |
1092 | 1090 | $block = new Block( |
1093 | | - /* $address */ $this->mName, |
1094 | | - /* $user */ $data['id'], |
1095 | | - /* $by */ 0, |
1096 | | - /* $reason */ $blockReason, |
1097 | | - /* $timestamp */ wfTimestampNow(), |
1098 | | - /* $auto */ false, |
1099 | | - /* $expiry */ Block::infinity(), |
1100 | | - /* anonOnly */ false, |
1101 | | - /* $createAccount */ true, |
1102 | | - /* $enableAutoblock */ true, |
1103 | | - /* $hideName (ipb_deleted) */ true, |
1104 | | - /* $blockEmail */ true, |
1105 | | - /* $allowUsertalk */ false, |
1106 | | - /* $byName */ $by |
1107 | | - ); |
1108 | | - |
| 1091 | + /* $address */ $this->mName, |
| 1092 | + /* $user */ $data['id'], |
| 1093 | + /* $by */ 0, |
| 1094 | + /* $reason */ $blockReason, |
| 1095 | + /* $timestamp */ wfTimestampNow(), |
| 1096 | + /* $auto */ false, |
| 1097 | + /* $expiry */ Block::infinity(), |
| 1098 | + /* anonOnly */ false, |
| 1099 | + /* $createAccount */ true, |
| 1100 | + /* $enableAutoblock */ true, |
| 1101 | + /* $hideName (ipb_deleted) */ true, |
| 1102 | + /* $blockEmail */ true, |
| 1103 | + /* $allowUsertalk */ false, |
| 1104 | + /* $byName */ $by |
| 1105 | + ); |
| 1106 | + |
1109 | 1107 | # On normal block, BlockIp hook would be run here, but doing |
1110 | 1108 | # that from CentralAuth doesn't seem a good idea... |
1111 | 1109 | |
— | — | @@ -1114,7 +1112,7 @@ |
1115 | 1113 | # Ditto for BlockIpComplete hook. |
1116 | 1114 | |
1117 | 1115 | IPBlockForm::suppressUserName( $this->mName, $data['id'], $dbw ); |
1118 | | - |
| 1116 | + |
1119 | 1117 | # Locally log to suppress ? |
1120 | 1118 | } else { |
1121 | 1119 | $dbw->delete( |
— | — | @@ -1192,7 +1190,7 @@ |
1193 | 1191 | "\00302$url\003 \0035*\003 \00303$user\003 \0035*\003\n"; |
1194 | 1192 | return $fullString; |
1195 | 1193 | } |
1196 | | - |
| 1194 | + |
1197 | 1195 | /** |
1198 | 1196 | * If the user provides the correct password, would we let them log in? |
1199 | 1197 | * This encompasses checks on missing and locked accounts, at present. |
— | — | @@ -1227,9 +1225,9 @@ |
1228 | 1226 | if ( ( $ret = $this->canAuthenticate() ) !== true ) { |
1229 | 1227 | return $ret; |
1230 | 1228 | } |
1231 | | - |
| 1229 | + |
1232 | 1230 | list( $salt, $crypt ) = $this->getPasswordHash(); |
1233 | | - |
| 1231 | + |
1234 | 1232 | if ( $this->matchHash( $password, $salt, $crypt ) ) { |
1235 | 1233 | wfDebugLog( 'CentralAuth', |
1236 | 1234 | "authentication for '$this->mName' succeeded" ); |
— | — | @@ -1240,7 +1238,7 @@ |
1241 | 1239 | return "bad password"; |
1242 | 1240 | } |
1243 | 1241 | } |
1244 | | - |
| 1242 | + |
1245 | 1243 | /** |
1246 | 1244 | * Attempt to authenticate the global user account with the given global authtoken |
1247 | 1245 | * @param string $token |
— | — | @@ -1250,7 +1248,7 @@ |
1251 | 1249 | if ( ( $ret = $this->canAuthenticate() ) !== true ) { |
1252 | 1250 | return $ret; |
1253 | 1251 | } |
1254 | | - |
| 1252 | + |
1255 | 1253 | if ( $this->validateAuthToken( $token ) ) { |
1256 | 1254 | return "ok"; |
1257 | 1255 | } else { |
— | — | @@ -1405,7 +1403,7 @@ |
1406 | 1404 | |
1407 | 1405 | return !empty( $rows ); |
1408 | 1406 | } |
1409 | | - |
| 1407 | + |
1410 | 1408 | /** |
1411 | 1409 | * Load the list of databases where this account has been successfully |
1412 | 1410 | * attached |
— | — | @@ -1415,19 +1413,19 @@ |
1416 | 1414 | // Already loaded |
1417 | 1415 | return; |
1418 | 1416 | } |
1419 | | - |
| 1417 | + |
1420 | 1418 | wfDebugLog( 'CentralAuth', "Loading attached wiki list for global user {$this->mName}." ); |
1421 | | - |
| 1419 | + |
1422 | 1420 | if ( isset( $this->mAttachedList ) ) { |
1423 | 1421 | wfDebugLog( 'CentralAuth', "-Found in cache." ); |
1424 | 1422 | // We have a list already, probably from the cache. |
1425 | 1423 | $this->mAttachedArray = explode( "\n", $this->mAttachedList ); |
1426 | | - |
| 1424 | + |
1427 | 1425 | return; |
1428 | 1426 | } |
1429 | | - |
| 1427 | + |
1430 | 1428 | wfDebugLog( 'CentralAuth', "-Loading from DB" ); |
1431 | | - |
| 1429 | + |
1432 | 1430 | $dbw = self::getCentralDB(); |
1433 | 1431 | |
1434 | 1432 | $result = $dbw->select( 'localuser', |
— | — | @@ -1440,7 +1438,7 @@ |
1441 | 1439 | $wikis[] = $row->lu_wiki; |
1442 | 1440 | } |
1443 | 1441 | $dbw->freeResult( $result ); |
1444 | | - |
| 1442 | + |
1445 | 1443 | $this->mAttachedArray = $wikis; |
1446 | 1444 | $this->mAttachedList = implode( "\n", $wikis ); |
1447 | 1445 | } |
— | — | @@ -1453,7 +1451,7 @@ |
1454 | 1452 | */ |
1455 | 1453 | public function listAttached() { |
1456 | 1454 | $this->loadAttached(); |
1457 | | - |
| 1455 | + |
1458 | 1456 | return $this->mAttachedArray; |
1459 | 1457 | } |
1460 | 1458 | |
— | — | @@ -1486,7 +1484,7 @@ |
1487 | 1485 | $row->lu_attached_timestamp ), |
1488 | 1486 | 'attachedMethod' => $row->lu_attached_method, |
1489 | 1487 | ); |
1490 | | - |
| 1488 | + |
1491 | 1489 | // Just for fun, add local user data. |
1492 | 1490 | // Displayed in the steward interface. |
1493 | 1491 | $wikis[$row->lu_wiki] = array_merge( $wikis[$row->lu_wiki], |
— | — | @@ -1652,7 +1650,7 @@ |
1653 | 1651 | |
1654 | 1652 | wfDebugLog( 'CentralAuth', |
1655 | 1653 | "Set global password for '$this->mName'" ); |
1656 | | - |
| 1654 | + |
1657 | 1655 | // Reset the auth token. |
1658 | 1656 | $this->resetAuthToken(); |
1659 | 1657 | $this->invalidateCache(); |
— | — | @@ -1670,11 +1668,11 @@ |
1671 | 1669 | } |
1672 | 1670 | return $this->mPassword; |
1673 | 1671 | } |
1674 | | - |
| 1672 | + |
1675 | 1673 | static function setCookie( $name, $value, $exp = -1 ) { |
1676 | 1674 | global $wgCentralAuthCookiePrefix, $wgCentralAuthCookieDomain, $wgCookieSecure, |
1677 | 1675 | $wgCookieExpiration, $wgCookieHttpOnly; |
1678 | | - |
| 1676 | + |
1679 | 1677 | if ( $exp == -1 ) { |
1680 | 1678 | $exp = time() + $wgCookieExpiration; |
1681 | 1679 | } elseif ( $exp == 0 ) { |
— | — | @@ -1685,7 +1683,7 @@ |
1686 | 1684 | $exp += time(); |
1687 | 1685 | } |
1688 | 1686 | $httpOnlySafe = version_compare( "5.2", PHP_VERSION, "<" ); |
1689 | | - |
| 1687 | + |
1690 | 1688 | if ( $httpOnlySafe && isset( $wgCookieHttpOnly ) ) { |
1691 | 1689 | setcookie( $wgCentralAuthCookiePrefix . $name, |
1692 | 1690 | $value, |
— | — | @@ -1705,7 +1703,7 @@ |
1706 | 1704 | $wgCookieSecure ); |
1707 | 1705 | } |
1708 | 1706 | } |
1709 | | - |
| 1707 | + |
1710 | 1708 | protected function clearCookie( $name ) { |
1711 | 1709 | global $wgCentralAuthCookiePrefix; |
1712 | 1710 | self::setCookie( $name, '', - 86400 ); |
— | — | @@ -1721,16 +1719,16 @@ |
1722 | 1720 | // Older code passed a user object here. Be kind and do what they meant to do. |
1723 | 1721 | $remember = $remember->getOption( 'rememberpassword' ); |
1724 | 1722 | } |
1725 | | - |
| 1723 | + |
1726 | 1724 | $session = array(); |
1727 | 1725 | $exp = time() + 86400; |
1728 | | - |
| 1726 | + |
1729 | 1727 | $session['user'] = $this->mName; |
1730 | 1728 | self::setCookie( 'User', $this->mName ); |
1731 | 1729 | $session['token'] = $this->getAuthToken(); |
1732 | 1730 | $session['expiry'] = $exp; |
1733 | 1731 | $session['auto-create-blacklist'] = array(); |
1734 | | - |
| 1732 | + |
1735 | 1733 | if ( $remember ) { |
1736 | 1734 | self::setCookie( 'Token', $this->getAuthToken() ); |
1737 | 1735 | } else { |
— | — | @@ -1738,31 +1736,31 @@ |
1739 | 1737 | } |
1740 | 1738 | return self::setSession( $session ); |
1741 | 1739 | } |
1742 | | - |
| 1740 | + |
1743 | 1741 | /** |
1744 | 1742 | * Delete global cookies which auto-authenticate the user on other wikis. |
1745 | 1743 | * Called on logout. |
1746 | 1744 | */ |
1747 | 1745 | function deleteGlobalCookies() { |
1748 | 1746 | global $wgCentralAuthCookiePrefix; |
1749 | | - |
| 1747 | + |
1750 | 1748 | $this->clearCookie( 'User' ); |
1751 | 1749 | $this->clearCookie( 'Token' ); |
1752 | 1750 | $this->clearCookie( 'Session' ); |
1753 | | - |
| 1751 | + |
1754 | 1752 | // Logged-out cookie -to fix caching. |
1755 | 1753 | self::setCookie( 'LoggedOut', wfTimestampNow() ); |
1756 | | - |
| 1754 | + |
1757 | 1755 | self::deleteSession(); |
1758 | 1756 | } |
1759 | | - |
| 1757 | + |
1760 | 1758 | /** |
1761 | 1759 | * Check a global auth token against the one we know of in the database. |
1762 | 1760 | */ |
1763 | 1761 | function validateAuthToken( $token ) { |
1764 | 1762 | return ( $token == $this->getAuthToken() ); |
1765 | 1763 | } |
1766 | | - |
| 1764 | + |
1767 | 1765 | /** |
1768 | 1766 | * Generate a new random auth token, and store it in the database. |
1769 | 1767 | * Should be called as often as possible, to the extent that it will |
— | — | @@ -1772,7 +1770,7 @@ |
1773 | 1771 | // Generate a random token. |
1774 | 1772 | $this->mAuthToken = wfGenerateToken( $this->getId() ); |
1775 | 1773 | $this->mStateDirty = true; |
1776 | | - |
| 1774 | + |
1777 | 1775 | // Save it. |
1778 | 1776 | $this->saveSettings(); |
1779 | 1777 | } |
— | — | @@ -1802,19 +1800,19 @@ |
1803 | 1801 | ), |
1804 | 1802 | __METHOD__ |
1805 | 1803 | ); |
1806 | | - |
| 1804 | + |
1807 | 1805 | $this->invalidateCache(); |
1808 | 1806 | } |
1809 | | - |
| 1807 | + |
1810 | 1808 | function getGlobalGroups() { |
1811 | 1809 | $this->loadGroups(); |
1812 | | - |
| 1810 | + |
1813 | 1811 | return $this->mGroups; |
1814 | 1812 | } |
1815 | | - |
| 1813 | + |
1816 | 1814 | function getGlobalRights() { |
1817 | 1815 | $this->loadGroups(); |
1818 | | - |
| 1816 | + |
1819 | 1817 | $rights = array(); |
1820 | 1818 | $sets = array(); |
1821 | 1819 | foreach ( $this->mRights as $right ) { |
— | — | @@ -1828,111 +1826,111 @@ |
1829 | 1827 | } |
1830 | 1828 | return $rights; |
1831 | 1829 | } |
1832 | | - |
| 1830 | + |
1833 | 1831 | function removeFromGlobalGroups( $groups ) { |
1834 | 1832 | $dbw = self::getCentralDB(); |
1835 | | - |
| 1833 | + |
1836 | 1834 | # Delete from the DB |
1837 | 1835 | $dbw->delete( 'global_user_groups', |
1838 | 1836 | array( 'gug_user' => $this->getId(), 'gug_group' => $groups ), |
1839 | 1837 | __METHOD__ ); |
1840 | | - |
| 1838 | + |
1841 | 1839 | $this->invalidateCache(); |
1842 | 1840 | } |
1843 | | - |
| 1841 | + |
1844 | 1842 | function addToGlobalGroups( $groups ) { |
1845 | 1843 | $dbw = self::getCentralDB(); |
1846 | | - |
| 1844 | + |
1847 | 1845 | if ( !is_array( $groups ) ) { |
1848 | 1846 | $groups = array( $groups ); |
1849 | 1847 | } |
1850 | | - |
| 1848 | + |
1851 | 1849 | $insert_rows = array(); |
1852 | 1850 | foreach ( $groups as $group ) { |
1853 | 1851 | $insert_rows[] = array( 'gug_user' => $this->getId(), 'gug_group' => $group ); |
1854 | 1852 | } |
1855 | | - |
| 1853 | + |
1856 | 1854 | # Replace into the DB |
1857 | 1855 | $dbw->replace( 'global_user_groups', |
1858 | 1856 | array( 'gug_user', 'gug_group' ), |
1859 | 1857 | $insert_rows, __METHOD__ ); |
1860 | | - |
| 1858 | + |
1861 | 1859 | $this->invalidateCache(); |
1862 | 1860 | } |
1863 | | - |
| 1861 | + |
1864 | 1862 | static function availableGlobalGroups() { |
1865 | 1863 | $dbr = self::getCentralSlaveDB(); |
1866 | | - |
| 1864 | + |
1867 | 1865 | $res = $dbr->select( 'global_group_permissions', 'distinct ggp_group', array(), __METHOD__ ); |
1868 | | - |
| 1866 | + |
1869 | 1867 | $groups = array(); |
1870 | | - |
| 1868 | + |
1871 | 1869 | while ( $row = $dbr->fetchObject( $res ) ) |
1872 | 1870 | $groups[] = $row->ggp_group; |
1873 | | - |
| 1871 | + |
1874 | 1872 | return $groups; |
1875 | 1873 | } |
1876 | | - |
| 1874 | + |
1877 | 1875 | static function globalGroupPermissions( $group ) { |
1878 | 1876 | $dbr = self::getCentralSlaveDB(); |
1879 | | - |
| 1877 | + |
1880 | 1878 | $res = $dbr->select( array( 'global_group_permissions' ), |
1881 | 1879 | array( 'ggp_permission' ), array( 'ggp_group' => $group ), __METHOD__ ); |
1882 | | - |
| 1880 | + |
1883 | 1881 | $rights = array(); |
1884 | | - |
| 1882 | + |
1885 | 1883 | while ( $row = $dbr->fetchObject( $res ) ) { |
1886 | 1884 | $rights[] = $row->ggp_permission; |
1887 | 1885 | } |
1888 | | - |
| 1886 | + |
1889 | 1887 | return $rights; |
1890 | 1888 | } |
1891 | | - |
| 1889 | + |
1892 | 1890 | function hasGlobalPermission( $perm ) { |
1893 | 1891 | $perms = $this->getGlobalRights(); |
1894 | | - |
| 1892 | + |
1895 | 1893 | return in_array( $perm, $perms ); |
1896 | 1894 | } |
1897 | | - |
| 1895 | + |
1898 | 1896 | static function getUsedRights() { |
1899 | 1897 | $dbr = self::getCentralSlaveDB(); |
1900 | | - |
| 1898 | + |
1901 | 1899 | $res = $dbr->select( 'global_group_permissions', 'distinct ggp_permission', |
1902 | 1900 | array(), __METHOD__ ); |
1903 | | - |
| 1901 | + |
1904 | 1902 | $rights = array(); |
1905 | | - |
| 1903 | + |
1906 | 1904 | while ( $row = $dbr->fetchObject( $res ) ) |
1907 | 1905 | $rights[] = $row->ggp_permission; |
1908 | | - |
| 1906 | + |
1909 | 1907 | return $rights; |
1910 | 1908 | } |
1911 | | - |
| 1909 | + |
1912 | 1910 | public function invalidateCache() { |
1913 | 1911 | if ( !$this->mDelayInvalidation ) { |
1914 | 1912 | wfDebugLog( 'CentralAuth', "Updating cache for global user {$this->mName}" ); |
1915 | | - |
| 1913 | + |
1916 | 1914 | // Reload the state |
1917 | 1915 | $this->loadStateNoCache(); |
1918 | | - |
| 1916 | + |
1919 | 1917 | // Overwrite the cache. |
1920 | 1918 | $this->saveToCache(); |
1921 | 1919 | } else { |
1922 | 1920 | wfDebugLog( 'CentralAuth', "Deferring cache invalidation because we're in a transaction" ); |
1923 | 1921 | } |
1924 | 1922 | } |
1925 | | - |
| 1923 | + |
1926 | 1924 | /** |
1927 | 1925 | * For when speed is of the essence (e.g. when batch-purging users after rights changes) |
1928 | 1926 | */ |
1929 | 1927 | public function quickInvalidateCache() { |
1930 | 1928 | global $wgMemc; |
1931 | | - |
| 1929 | + |
1932 | 1930 | wfDebugLog( 'CentralAuth', "Quick cache invalidation for global user {$this->mName}" ); |
1933 | | - |
| 1931 | + |
1934 | 1932 | $wgMemc->delete( $this->getCacheKey() ); |
1935 | 1933 | } |
1936 | | - |
| 1934 | + |
1937 | 1935 | /** |
1938 | 1936 | * End a "transaction". |
1939 | 1937 | * A transaction delays cache invalidation until after |
— | — | @@ -1944,7 +1942,7 @@ |
1945 | 1943 | $this->mDelayInvalidation = false; |
1946 | 1944 | $this->invalidateCache(); |
1947 | 1945 | } |
1948 | | - |
| 1946 | + |
1949 | 1947 | /** |
1950 | 1948 | * Start a "transaction". |
1951 | 1949 | * A transaction delays cache invalidation until after |
— | — | @@ -2023,7 +2021,7 @@ |
2024 | 2022 | $key = self::memcKey( 'session', $id ); |
2025 | 2023 | $wgMemc->delete( $key ); |
2026 | 2024 | } |
2027 | | - |
| 2025 | + |
2028 | 2026 | /** |
2029 | 2027 | * Check if the user is attached on a given wiki id. |
2030 | 2028 | */ |
Index: trunk/extensions/CentralAuth/SpecialGlobalGroupPermissions.php |
— | — | @@ -1,5 +1,4 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | # This file is part of MediaWiki. |
5 | 4 | |
6 | 5 | # MediaWiki is free software: you can redistribute it and/or modify |
— | — | @@ -23,7 +22,6 @@ |
24 | 23 | exit( 1 ); |
25 | 24 | } |
26 | 25 | |
27 | | - |
28 | 26 | class SpecialGlobalGroupPermissions extends SpecialPage { |
29 | 27 | function __construct() { |
30 | 28 | parent::__construct( 'GlobalGroupPermissions' ); |
Index: trunk/extensions/CentralAuth/CentralAuth.php |
— | — | @@ -1,5 +1,4 @@ |
2 | 2 | <?php |
3 | | - |
4 | 3 | /** |
5 | 4 | * Extension credits |
6 | 5 | */ |
— | — | @@ -24,10 +23,10 @@ |
25 | 24 | * |
26 | 25 | * If this is not on the primary database connection, don't forget |
27 | 26 | * to also set up $wgDBservers to have an entry with a groupLoads |
28 | | - * setting for the 'CentralAuth' group. Alternatively you can use |
| 27 | + * setting for the 'CentralAuth' group. Alternatively you can use |
29 | 28 | * $wgLBFactoryConf to set up an LBFactory_Multi object. |
30 | 29 | * |
31 | | - * To use a database with a table prefix, set this variable to |
| 30 | + * To use a database with a table prefix, set this variable to |
32 | 31 | * "{$database}-{$prefix}". |
33 | 32 | */ |
34 | 33 | $wgCentralAuthDatabase = 'centralauth'; |
— | — | @@ -84,15 +83,15 @@ |
85 | 84 | $wgCentralAuthCookiePrefix = 'centralauth_'; |
86 | 85 | |
87 | 86 | /** |
88 | | - * List of wiki IDs which should be called on login/logout to set third-party |
| 87 | + * List of wiki IDs which should be called on login/logout to set third-party |
89 | 88 | * cookies for the global session state. |
90 | 89 | * |
91 | | - * The wiki ID is typically the database name, except when table prefixes are |
92 | | - * used, in which case it is the database name, a hyphen separator, and then |
| 90 | + * The wiki ID is typically the database name, except when table prefixes are |
| 91 | + * used, in which case it is the database name, a hyphen separator, and then |
93 | 92 | * the table prefix. |
94 | 93 | * |
95 | | - * This allows a farm with multiple second-level domains to set up a global |
96 | | - * session on all of them by hitting one wiki from each domain |
| 94 | + * This allows a farm with multiple second-level domains to set up a global |
| 95 | + * session on all of them by hitting one wiki from each domain |
97 | 96 | * (en.wikipedia.org, en.wikinews.org, etc). |
98 | 97 | * |
99 | 98 | * Done by $wgCentralAuthLoginIcon from Special:AutoLogin on each wiki. |
— | — | @@ -238,26 +237,32 @@ |
239 | 238 | |
240 | 239 | $wgLogTypes[] = 'gblrights'; |
241 | 240 | $wgLogNames['gblrights'] = 'centralauth-rightslog-name'; |
242 | | -$wgLogHeaders['gblrights'] = 'centralauth-rightslog-header'; |
| 241 | +$wgLogHeaders['gblrights'] = 'centralauth-rightslog-header'; |
243 | 242 | $wgLogActions['gblrights/usergroups'] = 'centralauth-rightslog-entry-usergroups'; |
244 | 243 | $wgLogActions['gblrights/groupperms'] = 'centralauth-rightslog-entry-groupperms'; |
245 | 244 | $wgLogActions['gblrights/groupprms2'] = 'centralauth-rightslog-entry-groupperms2'; |
246 | 245 | $wgLogActions['gblrights/groupprms3'] = 'centralauth-rightslog-entry-groupperms3'; |
247 | | -foreach( array( 'newset', 'setrename', 'setnewtype', 'setchange', 'deleteset' ) as $type ) |
| 246 | + |
| 247 | +foreach ( array( 'newset', 'setrename', 'setnewtype', 'setchange', 'deleteset' ) as $type ) |
248 | 248 | $wgLogActionsHandlers["gblrights/{$type}"] = 'efHandleWikiSetLogEntry'; |
249 | 249 | |
250 | 250 | function efHandleWikiSetLogEntry( $type, $action, $title, $skin, $params, $filterWikilinks = false ) { |
251 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 251 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
252 | 252 | $link = $skin ? $skin->makeLinkObj( $title, $params[0] ) : $params[0]; |
253 | | - if( $action == 'newset' ) |
| 253 | + if ( $action == 'newset' ) { |
254 | 254 | $args = array( WikiSet::formatType( $params[1] ), $params[2] ); |
255 | | - if( $action == 'setrename' ) |
| 255 | + } |
| 256 | + if ( $action == 'setrename' ) { |
256 | 257 | $args = array( $params[1] ); |
257 | | - if( $action == 'setnewtype' ) |
| 258 | + } |
| 259 | + if ( $action == 'setnewtype' ) { |
258 | 260 | $args = array( WikiSet::formatType( $params[1] ), WikiSet::formatType( $params[2] ) ); |
259 | | - if( $action == 'setchange' ) |
| 261 | + } |
| 262 | + if ( $action == 'setchange' ) { |
260 | 263 | $args = array( $params[1] ? $params[1] : wfMsg( 'rightsnone' ), $params[2] ? $params[2] : wfMsg( 'rightsnone' ) ); |
261 | | - if( $action == 'deleteset' ) |
| 264 | + } |
| 265 | + if ( $action == 'deleteset' ) { |
262 | 266 | $args = array(); |
| 267 | + } |
263 | 268 | return wfMsgReal( "centralauth-rightslog-entry-{$action}", array_merge( array( $link ), $args ), true, !$skin ); |
264 | 269 | } |
Index: trunk/extensions/CentralAuth/SpecialCentralAuth.php |
— | — | @@ -4,7 +4,7 @@ |
5 | 5 | var $mGlobalUser, $mAttachedLocalAccounts, $mUnattachedLocalAccounts; |
6 | 6 | |
7 | 7 | function __construct() { |
8 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 8 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
9 | 9 | parent::__construct( 'CentralAuth' ); |
10 | 10 | } |
11 | 11 | |
— | — | @@ -62,7 +62,7 @@ |
63 | 63 | } |
64 | 64 | |
65 | 65 | $continue = true; |
66 | | - if( $this->mCanEdit && $this->mPosted ) { |
| 66 | + if ( $this->mCanEdit && $this->mPosted ) { |
67 | 67 | $continue = $this->doSubmit(); |
68 | 68 | } |
69 | 69 | |
— | — | @@ -72,11 +72,11 @@ |
73 | 73 | $this->showUsernameForm(); |
74 | 74 | if ( $continue ) { |
75 | 75 | $this->showInfo(); |
76 | | - if( $this->mCanLock ) |
| 76 | + if ( $this->mCanLock ) |
77 | 77 | $this->showStatusForm(); |
78 | | - if( $this->mCanUnmerge ) |
| 78 | + if ( $this->mCanUnmerge ) |
79 | 79 | $this->showActionForm( 'delete' ); |
80 | | - if( $this->mCanEdit ) |
| 80 | + if ( $this->mCanEdit ) |
81 | 81 | $this->showLogExtract(); |
82 | 82 | $this->showWikiLists(); |
83 | 83 | } |
— | — | @@ -89,7 +89,7 @@ |
90 | 90 | global $wgUser, $wgOut, $wgRequest; |
91 | 91 | if ( !$wgUser->matchEditToken( $wgRequest->getVal( 'wpEditToken' ) ) ) { |
92 | 92 | $this->showError( 'centralauth-token-mismatch' ); |
93 | | - } elseif( $this->mMethod == 'unmerge' && $this->mCanUnmerge ) { |
| 93 | + } elseif ( $this->mMethod == 'unmerge' && $this->mCanUnmerge ) { |
94 | 94 | $status = $globalUser->adminUnattach( $this->mWikis ); |
95 | 95 | if ( !$status->isGood() ) { |
96 | 96 | $this->showStatusError( $status->getWikiText() ); |
— | — | @@ -123,22 +123,22 @@ |
124 | 124 | CentralAuthUser::HIDDEN_NONE, |
125 | 125 | CentralAuthUser::HIDDEN_LISTS, |
126 | 126 | CentralAuthUser::HIDDEN_OVERSIGHT ); |
127 | | - if( !in_array( $setHidden, $hiddenLevels ) ) |
| 127 | + if ( !in_array( $setHidden, $hiddenLevels ) ) |
128 | 128 | $setHidden = ''; |
129 | 129 | |
130 | 130 | if ( !$isLocked && $setLocked ) { |
131 | 131 | $lockStatus = $globalUser->adminLock(); |
132 | 132 | $added[] = wfMsgForContent( 'centralauth-log-status-locked' ); |
133 | | - } elseif( $isLocked && !$setLocked ) { |
| 133 | + } elseif ( $isLocked && !$setLocked ) { |
134 | 134 | $lockStatus = $globalUser->adminUnlock(); |
135 | 135 | $removed[] = wfMsgForContent( 'centralauth-log-status-locked' ); |
136 | 136 | } |
137 | 137 | |
138 | 138 | $reason = $wgRequest->getText( 'wpReasonList' ); |
139 | 139 | $reasonDetail = $wgRequest->getText( 'wpReason' ); |
140 | | - if( $reason == 'other' ) { |
| 140 | + if ( $reason == 'other' ) { |
141 | 141 | $reason = $reasonDetail; |
142 | | - } elseif( $reasonDetail ) { |
| 142 | + } elseif ( $reasonDetail ) { |
143 | 143 | $reason .= wfMsgForContent( 'colon-separator' ) . $reasonDetail; |
144 | 144 | } |
145 | 145 | |
— | — | @@ -152,31 +152,31 @@ |
153 | 153 | break; |
154 | 154 | case CentralAuthUser::HIDDEN_LISTS: |
155 | 155 | $added[] = wfMsgForContent( 'centralauth-log-status-hidden' ); |
156 | | - if( $oldHiddenLevel == CentralAuthUser::HIDDEN_OVERSIGHT ) |
| 156 | + if ( $oldHiddenLevel == CentralAuthUser::HIDDEN_OVERSIGHT ) |
157 | 157 | $removed[] = wfMsgForContent( 'centralauth-log-status-oversighted' ); |
158 | 158 | break; |
159 | 159 | case CentralAuthUser::HIDDEN_OVERSIGHT: |
160 | 160 | $added[] = wfMsgForContent( 'centralauth-log-status-oversighted' ); |
161 | | - if( $oldHiddenLevel == CentralAuthUser::HIDDEN_LISTS ) |
| 161 | + if ( $oldHiddenLevel == CentralAuthUser::HIDDEN_LISTS ) |
162 | 162 | $removed[] = wfMsgForContent( 'centralauth-log-status-hidden' ); |
163 | 163 | break; |
164 | 164 | } |
165 | 165 | |
166 | | - if( $setHidden == CentralAuthUser::HIDDEN_OVERSIGHT ) |
| 166 | + if ( $setHidden == CentralAuthUser::HIDDEN_OVERSIGHT ) |
167 | 167 | $globalUser->suppress( $reason ); |
168 | | - elseif( $oldHiddenLevel == CentralAuthUser::HIDDEN_OVERSIGHT ) |
| 168 | + elseif ( $oldHiddenLevel == CentralAuthUser::HIDDEN_OVERSIGHT ) |
169 | 169 | $globalUser->unsuppress( $reason ); |
170 | 170 | } |
171 | 171 | |
172 | 172 | $good = |
173 | | - ( is_null($lockStatus) || $lockStatus->isGood() ) && |
174 | | - ( is_null($hideStatus) || $hideStatus->isGood() ); |
| 173 | + ( is_null( $lockStatus ) || $lockStatus->isGood() ) && |
| 174 | + ( is_null( $hideStatus ) || $hideStatus->isGood() ); |
175 | 175 | |
176 | 176 | // Logging etc |
177 | | - if ( $good && (count($added) || count($removed)) ) { |
178 | | - $added = count($added) ? |
| 177 | + if ( $good && ( count( $added ) || count( $removed ) ) ) { |
| 178 | + $added = count( $added ) ? |
179 | 179 | implode( ', ', $added ) : wfMsgForContent( 'centralauth-log-status-none' ); |
180 | | - $removed = count($removed) ? |
| 180 | + $removed = count( $removed ) ? |
181 | 181 | implode( ', ', $removed ) : wfMsgForContent( 'centralauth-log-status-none' ); |
182 | 182 | |
183 | 183 | $this->logAction( |
— | — | @@ -187,11 +187,11 @@ |
188 | 188 | $setHidden == CentralAuthUser::HIDDEN_OVERSIGHT |
189 | 189 | ); |
190 | 190 | $this->showSuccess( 'centralauth-admin-setstatus-success', $this->mUserName ); |
191 | | - } elseif (!$good) { |
192 | | - if ( !is_null($lockStatus) && !$lockStatus->isGood() ) { |
| 191 | + } elseif ( !$good ) { |
| 192 | + if ( !is_null( $lockStatus ) && !$lockStatus->isGood() ) { |
193 | 193 | $this->showStatusError( $lockStatus->getWikiText() ); |
194 | 194 | } |
195 | | - if ( !is_null($hideStatus) && !$hideStatus->isGood() ) { |
| 195 | + if ( !is_null( $hideStatus ) && !$hideStatus->isGood() ) { |
196 | 196 | $this->showStatusError( $hideStatus->getWikiText() ); |
197 | 197 | } |
198 | 198 | } |
— | — | @@ -253,11 +253,11 @@ |
254 | 254 | 'days' => 30.417, |
255 | 255 | 'months' => 12, |
256 | 256 | 'years' => 1 ); |
257 | | - foreach( $units as $unit => $chunk ) { |
| 257 | + foreach ( $units as $unit => $chunk ) { |
258 | 258 | // Used messaged (to make sure that grep finds them): |
259 | 259 | // 'centralauth-seconds-ago', 'centralauth-minutes-ago', 'centralauth-hours-ago' |
260 | 260 | // 'centralauth-days-ago', 'centralauth-months-ago', 'centralauth-years-ago' |
261 | | - if( $span < 2*$chunk ) { |
| 261 | + if ( $span < 2 * $chunk ) { |
262 | 262 | return wfMsgExt( "centralauth-$unit-ago", 'parsemag', $wgLang->formatNum( $span ) ); |
263 | 263 | } |
264 | 264 | $span = $wgLang->formatNum( intval( $span / $chunk ) ); |
— | — | @@ -280,7 +280,7 @@ |
281 | 281 | 'hidden' => $this->formatHiddenLevel( $globalUser->getHiddenLevel() ) ); |
282 | 282 | $out = '<fieldset id="mw-centralauth-info">'; |
283 | 283 | $out .= '<legend>' . wfMsgHtml( 'centralauth-admin-info-header' ) . '</legend>'; |
284 | | - foreach( $attribs as $tag => $data ) { |
| 284 | + foreach ( $attribs as $tag => $data ) { |
285 | 285 | $out .= '<p><strong>' . wfMsgHtml( "centralauth-admin-info-$tag" ) . '</strong> ' . |
286 | 286 | htmlspecialchars( $data ) . '</p>'; |
287 | 287 | } |
— | — | @@ -300,7 +300,7 @@ |
301 | 301 | $wgOut->addHTML( "<fieldset><legend>{$legend}</legend>" ); |
302 | 302 | $wgOut->addHTML( $this->listHeader() ); |
303 | 303 | $wgOut->addHTML( $this->listMerged( $merged ) ); |
304 | | - if( $remainder ) |
| 304 | + if ( $remainder ) |
305 | 305 | $wgOut->addHTML( $this->listRemainder( $remainder ) ); |
306 | 306 | $wgOut->addHTML( $this->listFooter() ); |
307 | 307 | $wgOut->addHTML( '</fieldset>' ); |
— | — | @@ -320,18 +320,18 @@ |
321 | 321 | Xml::openElement( 'table', array( 'class' => 'wikitable sortable mw-centralauth-wikislist' ) ) . "\n" . |
322 | 322 | '<thead><tr>' . |
323 | 323 | ( $this->mCanUnmerge ? '<th></th>' : '' ) . |
324 | | - '<th>' . wfMsgHtml( 'centralauth-admin-list-localwiki' ) . '</th>'. |
| 324 | + '<th>' . wfMsgHtml( 'centralauth-admin-list-localwiki' ) . '</th>' . |
325 | 325 | '<th>' . wfMsgHtml( 'centralauth-admin-list-attached-on' ) . '</th>' . |
326 | 326 | '<th>' . wfMsgHtml( 'centralauth-admin-list-method' ) . '</th>' . |
327 | 327 | '<th>' . wfMsgHtml( 'centralauth-admin-list-blocked' ) . '</th>' . |
328 | | - '<th>' . wfMsgHtml( 'centralauth-admin-list-editcount' ) . '</th>'. |
| 328 | + '<th>' . wfMsgHtml( 'centralauth-admin-list-editcount' ) . '</th>' . |
329 | 329 | '</tr></thead>' . |
330 | 330 | '<tbody>'; |
331 | 331 | } |
332 | 332 | |
333 | 333 | function listFooter() { |
334 | 334 | $footer = ''; |
335 | | - if( $this->mCanUnmerge ) |
| 335 | + if ( $this->mCanUnmerge ) |
336 | 336 | $footer .= |
337 | 337 | '<tr>' . |
338 | 338 | '<td style="border-right: none"></td>' . |
— | — | @@ -364,7 +364,7 @@ |
365 | 365 | function listMergedWikiItem( $row ) { |
366 | 366 | global $wgLang; |
367 | 367 | return '<tr>' . |
368 | | - ( $this->mCanUnmerge ? '<td>' . $this->adminCheck( $row['wiki'] ) . '</td>' : '' ). |
| 368 | + ( $this->mCanUnmerge ? '<td>' . $this->adminCheck( $row['wiki'] ) . '</td>' : '' ) . |
369 | 369 | '<td>' . $this->foreignUserLink( $row['wiki'] ) . '</td>' . |
370 | 370 | '<td>' . |
371 | 371 | // invisible, to make this column sortable |
— | — | @@ -388,8 +388,8 @@ |
389 | 389 | } |
390 | 390 | |
391 | 391 | function formatBlockStatus( $row ) { |
392 | | - if( $row['blocked'] ) { |
393 | | - if( $row['block-expiry'] == 'infinity' ) { |
| 392 | + if ( $row['blocked'] ) { |
| 393 | + if ( $row['block-expiry'] == 'infinity' ) { |
394 | 394 | $reason = $row['block-reason']; |
395 | 395 | return wfMsgExt( 'centralauth-admin-blocked-indef', 'parseinline', array( $reason ) ); |
396 | 396 | } else { |
— | — | @@ -444,13 +444,13 @@ |
445 | 445 | $wiki = $wikiID; |
446 | 446 | } else { |
447 | 447 | $wiki = WikiMap::getWiki( $wikiID ); |
448 | | - if( !$wiki ) { |
| 448 | + if ( !$wiki ) { |
449 | 449 | throw new MWException( "Invalid wiki: $wikiID" ); |
450 | 450 | } |
451 | 451 | } |
452 | 452 | |
453 | 453 | $url = $wiki->getUrl( $title ); |
454 | | - if( $params ) |
| 454 | + if ( $params ) |
455 | 455 | $url .= '?' . $params; |
456 | 456 | return Xml::element( 'a', |
457 | 457 | array( |
— | — | @@ -462,7 +462,7 @@ |
463 | 463 | |
464 | 464 | function foreignUserLink( $wikiID ) { |
465 | 465 | $wiki = WikiMap::getWiki( $wikiID ); |
466 | | - if( !$wiki ) { |
| 466 | + if ( !$wiki ) { |
467 | 467 | throw new MWException( "Invalid wiki: $wikiID" ); |
468 | 468 | } |
469 | 469 | |
— | — | @@ -538,7 +538,7 @@ |
539 | 539 | 'mw-centralauth-status-hidden-list', |
540 | 540 | $this->mGlobalUser->getHiddenLevel() == CentralAuthUser::HIDDEN_LISTS ) . |
541 | 541 | '<br />'; |
542 | | - if( $this->mCanOversight ) { |
| 542 | + if ( $this->mCanOversight ) { |
543 | 543 | $radioHidden .= Xml::radioLabel( |
544 | 544 | wfMsgExt( 'centralauth-admin-status-hidden-oversight', array( 'parseinline' ) ), |
545 | 545 | 'wpStatusHidden', |
— | — | @@ -589,14 +589,14 @@ |
590 | 590 | Title::newFromText( "User:{$user}@global" )->getPrefixedText(), |
591 | 591 | '', |
592 | 592 | array( 'showIfEmpty' => true ) ); |
593 | | - if( $numRows ) { |
| 593 | + if ( $numRows ) { |
594 | 594 | $wgOut->addHTML( Xml::fieldset( wfMsg( 'centralauth-admin-logsnippet' ), $text ) ); |
595 | 595 | } |
596 | 596 | } |
597 | 597 | |
598 | 598 | function determineHomeWiki() { |
599 | | - foreach( $this->mAttachedLocalAccounts as $wiki => $acc ) { |
600 | | - if( $acc['attachedMethod'] == 'primary' || $acc['attachedMethod'] == 'new' ) { |
| 599 | + foreach ( $this->mAttachedLocalAccounts as $wiki => $acc ) { |
| 600 | + if ( $acc['attachedMethod'] == 'primary' || $acc['attachedMethod'] == 'new' ) { |
601 | 601 | return $wiki; |
602 | 602 | } |
603 | 603 | } |
— | — | @@ -607,7 +607,7 @@ |
608 | 608 | |
609 | 609 | function evaluateTotalEditcount() { |
610 | 610 | $total = 0; |
611 | | - foreach( $this->mAttachedLocalAccounts as $acc ) { |
| 611 | + foreach ( $this->mAttachedLocalAccounts as $acc ) { |
612 | 612 | $total += $acc['editCount']; |
613 | 613 | } |
614 | 614 | return $total; |
— | — | @@ -616,7 +616,7 @@ |
617 | 617 | function addMergeMethodDescriptions() { |
618 | 618 | global $wgOut, $wgLang; |
619 | 619 | $js = "wgMergeMethodDescriptions = {\n"; |
620 | | - foreach( array( 'primary', 'new', 'empty', 'password', 'mail', 'admin', 'login' ) as $method ) { |
| 620 | + foreach ( array( 'primary', 'new', 'empty', 'password', 'mail', 'admin', 'login' ) as $method ) { |
621 | 621 | $short = Xml::encodeJsVar( $wgLang->ucfirst( wfMsgHtml( "centralauth-merge-method-{$method}" ) ) ); |
622 | 622 | $desc = Xml::encodeJsVar( wfMsgWikiHtml( "centralauth-merge-method-{$method}-desc" ) ); |
623 | 623 | $js .= "\t'{$method}' : { 'short' : {$short}, 'desc' : {$desc} },\n"; |
Index: trunk/extensions/CentralAuth/SpecialMergeAccount.php |
— | — | @@ -1,9 +1,8 @@ |
2 | 2 | <?php |
3 | 3 | |
4 | 4 | class SpecialMergeAccount extends SpecialPage { |
5 | | - |
6 | 5 | function __construct() { |
7 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 6 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
8 | 7 | parent::__construct( 'MergeAccount', 'centralauth-merge' ); |
9 | 8 | } |
10 | 9 | |
— | — | @@ -19,7 +18,7 @@ |
20 | 19 | return; |
21 | 20 | } |
22 | 21 | |
23 | | - if( !$wgUser->isLoggedIn() ) { |
| 22 | + if ( !$wgUser->isLoggedIn() ) { |
24 | 23 | $wgOut->addWikiText( |
25 | 24 | wfMsg( 'centralauth-merge-notlogged' ) . |
26 | 25 | "\n\n" . |
— | — | @@ -27,7 +26,7 @@ |
28 | 27 | |
29 | 28 | return; |
30 | 29 | } |
31 | | - |
| 30 | + |
32 | 31 | if ( wfReadOnly() ) { |
33 | 32 | $wgOut->setPagetitle( wfMsg( 'readonly' ) ); |
34 | 33 | $wgOut->addWikiMsg( 'readonlytext', wfReadOnlyReason() ); |
— | — | @@ -56,7 +55,7 @@ |
57 | 56 | // did / did not merge some accounts |
58 | 57 | // do / don't have more accounts to merge |
59 | 58 | |
60 | | - if( $this->mAttemptMerge ) { |
| 59 | + if ( $this->mAttemptMerge ) { |
61 | 60 | switch( $this->mMergeAction ) { |
62 | 61 | case "dryrun": |
63 | 62 | return $this->doDryRunMerge(); |
— | — | @@ -74,8 +73,8 @@ |
75 | 74 | } |
76 | 75 | |
77 | 76 | $globalUser = new CentralAuthUser( $this->mUserName ); |
78 | | - if( $globalUser->exists() ) { |
79 | | - if( $globalUser->isAttached() ) { |
| 77 | + if ( $globalUser->exists() ) { |
| 78 | + if ( $globalUser->isAttached() ) { |
80 | 79 | $this->showCleanupForm(); |
81 | 80 | } else { |
82 | 81 | $this->showAttachForm(); |
— | — | @@ -101,7 +100,7 @@ |
102 | 101 | |
103 | 102 | // Generate a random binary string |
104 | 103 | $key = ''; |
105 | | - for( $i = 0; $i < 128; $i++ ) { |
| 104 | + for ( $i = 0; $i < 128; $i++ ) { |
106 | 105 | $key .= chr( mt_rand( 0, 255 ) ); |
107 | 106 | } |
108 | 107 | $this->mSessionKey = $key; |
— | — | @@ -115,7 +114,7 @@ |
116 | 115 | $_SESSION['wsCentralAuthMigration'][$this->mSessionToken], |
117 | 116 | $this->mSessionKey ) ) ); |
118 | 117 | wfRestoreWarnings(); |
119 | | - if( is_array( $passwords ) ) { |
| 118 | + if ( is_array( $passwords ) ) { |
120 | 119 | return $passwords; |
121 | 120 | } |
122 | 121 | return array(); |
— | — | @@ -123,7 +122,7 @@ |
124 | 123 | |
125 | 124 | private function addWorkingPassword( $password ) { |
126 | 125 | $passwords = $this->getWorkingPasswords(); |
127 | | - if( !in_array( $password, $passwords ) ) { |
| 126 | + if ( !in_array( $password, $passwords ) ) { |
128 | 127 | $passwords[] = $password; |
129 | 128 | } |
130 | 129 | |
— | — | @@ -142,25 +141,23 @@ |
143 | 142 | } |
144 | 143 | |
145 | 144 | function xorString( $text, $key ) { |
146 | | - if( $key != '' ) { |
147 | | - for( $i = 0; $i < strlen( $text ); $i++ ) { |
148 | | - $text[$i] = chr(0xff & (ord($text[$i]) ^ ord($key[$i % strlen( $key )]))); |
| 145 | + if ( $key != '' ) { |
| 146 | + for ( $i = 0; $i < strlen( $text ); $i++ ) { |
| 147 | + $text[$i] = chr( 0xff & ( ord( $text[$i] ) ^ ord( $key[$i % strlen( $key )] ) ) ); |
149 | 148 | } |
150 | 149 | } |
151 | 150 | return $text; |
152 | 151 | } |
153 | 152 | |
154 | | - |
155 | | - |
156 | 153 | function doDryRunMerge() { |
157 | 154 | global $wgUser, $wgRequest, $wgOut, $wgCentralAuthDryRun; |
158 | 155 | $globalUser = new CentralAuthUser( $wgUser->getName() ); |
159 | 156 | |
160 | | - if( $globalUser->exists() ) { |
| 157 | + if ( $globalUser->exists() ) { |
161 | 158 | throw new MWException( "Already exists -- race condition" ); |
162 | 159 | } |
163 | 160 | |
164 | | - if( $wgCentralAuthDryRun ) { |
| 161 | + if ( $wgCentralAuthDryRun ) { |
165 | 162 | $wgOut->addWikiText( wfMsg( 'centralauth-notice-dryrun' ) ); |
166 | 163 | } |
167 | 164 | |
— | — | @@ -174,16 +171,16 @@ |
175 | 172 | $methods = array(); |
176 | 173 | $status = $globalUser->migrationDryRun( $passwords, $home, $attached, $unattached, $methods ); |
177 | 174 | |
178 | | - if( $status->isGood() ) { |
| 175 | + if ( $status->isGood() ) { |
179 | 176 | // This is the global account or matched it |
180 | | - if( count( $unattached ) == 0 ) { |
| 177 | + if ( count( $unattached ) == 0 ) { |
181 | 178 | // Everything matched -- very convenient! |
182 | 179 | $wgOut->addWikiText( wfMsg( 'centralauth-merge-dryrun-complete' ) ); |
183 | 180 | } else { |
184 | 181 | $wgOut->addWikiText( wfMsg( 'centralauth-merge-dryrun-incomplete' ) ); |
185 | 182 | } |
186 | 183 | |
187 | | - if( count( $unattached ) > 0 ) { |
| 184 | + if ( count( $unattached ) > 0 ) { |
188 | 185 | $wgOut->addHTML( $this->step2PasswordForm( $unattached ) ); |
189 | 186 | $wgOut->addWikiText( wfMsg( 'centralauth-merge-dryrun-or' ) ); |
190 | 187 | } |
— | — | @@ -197,7 +194,7 @@ |
198 | 195 | $wgOut->addHTML( '</div>' ); |
199 | 196 | |
200 | 197 | // Show wiki list if required |
201 | | - if ( $status->hasMessage( 'centralauth-blocked-text' ) |
| 198 | + if ( $status->hasMessage( 'centralauth-blocked-text' ) |
202 | 199 | || $status->hasMessage( 'centralauth-merge-home-password' ) ) |
203 | 200 | { |
204 | 201 | $out = '<h2>' . wfMsgHtml( 'centralauth-list-home-title' ) . '</h2>'; |
— | — | @@ -215,16 +212,16 @@ |
216 | 213 | global $wgUser, $wgRequest, $wgOut, $wgCentralAuthDryRun; |
217 | 214 | $globalUser = new CentralAuthUser( $wgUser->getName() ); |
218 | 215 | |
219 | | - if( $wgCentralAuthDryRun ) { |
| 216 | + if ( $wgCentralAuthDryRun ) { |
220 | 217 | return $this->dryRunError(); |
221 | 218 | } |
222 | 219 | |
223 | | - if( $globalUser->exists() ) { |
| 220 | + if ( $globalUser->exists() ) { |
224 | 221 | throw new MWException( "Already exists -- race condition" ); |
225 | 222 | } |
226 | 223 | |
227 | 224 | $passwords = $this->getWorkingPasswords(); |
228 | | - if( empty( $passwords ) ) { |
| 225 | + if ( empty( $passwords ) ) { |
229 | 226 | throw new MWException( "Submission error -- invalid input" ); |
230 | 227 | } |
231 | 228 | |
— | — | @@ -241,15 +238,15 @@ |
242 | 239 | global $wgUser, $wgRequest, $wgOut, $wgCentralAuthDryRun; |
243 | 240 | $globalUser = new CentralAuthUser( $wgUser->getName() ); |
244 | 241 | |
245 | | - if( !$globalUser->exists() ) { |
| 242 | + if ( !$globalUser->exists() ) { |
246 | 243 | throw new MWException( "User doesn't exist -- race condition?" ); |
247 | 244 | } |
248 | 245 | |
249 | | - if( !$globalUser->isAttached() ) { |
| 246 | + if ( !$globalUser->isAttached() ) { |
250 | 247 | throw new MWException( "Can't cleanup merge if not already attached." ); |
251 | 248 | } |
252 | 249 | |
253 | | - if( $wgCentralAuthDryRun ) { |
| 250 | + if ( $wgCentralAuthDryRun ) { |
254 | 251 | return $this->dryRunError(); |
255 | 252 | } |
256 | 253 | $password = $wgRequest->getText( 'wpPassword' ); |
— | — | @@ -260,8 +257,8 @@ |
261 | 258 | $ok = $globalUser->attemptPasswordMigration( $password, $attached, $unattached ); |
262 | 259 | $this->clearWorkingPasswords(); |
263 | 260 | |
264 | | - if( !$ok ) { |
265 | | - if( empty( $attached ) ) { |
| 261 | + if ( !$ok ) { |
| 262 | + if ( empty( $attached ) ) { |
266 | 263 | $wgOut->addWikiText( wfMsg( 'centralauth-finish-noconfirms' ) ); |
267 | 264 | } else { |
268 | 265 | $wgOut->addWikiText( wfMsg( 'centralauth-finish-incomplete' ) ); |
— | — | @@ -274,19 +271,19 @@ |
275 | 272 | global $wgUser, $wgRequest, $wgOut, $wgCentralAuthDryRun; |
276 | 273 | $globalUser = new CentralAuthUser( $wgUser->getName() ); |
277 | 274 | |
278 | | - if( !$globalUser->exists() ) { |
| 275 | + if ( !$globalUser->exists() ) { |
279 | 276 | throw new MWException( "User doesn't exist -- race condition?" ); |
280 | 277 | } |
281 | 278 | |
282 | | - if( $globalUser->isAttached() ) { |
| 279 | + if ( $globalUser->isAttached() ) { |
283 | 280 | throw new MWException( "Already attached -- race condition?" ); |
284 | 281 | } |
285 | 282 | |
286 | | - if( $wgCentralAuthDryRun ) { |
| 283 | + if ( $wgCentralAuthDryRun ) { |
287 | 284 | return $this->dryRunError(); |
288 | 285 | } |
289 | 286 | $password = $wgRequest->getText( 'wpPassword' ); |
290 | | - if( $globalUser->authenticate( $password ) == 'ok' ) { |
| 287 | + if ( $globalUser->authenticate( $password ) == 'ok' ) { |
291 | 288 | $globalUser->attach( wfWikiID(), 'password' ); |
292 | 289 | $wgOut->addWikiText( wfMsg( 'centralauth-attach-success' ) ); |
293 | 290 | $this->showCleanupForm(); |
— | — | @@ -302,7 +299,7 @@ |
303 | 300 | private function showWelcomeForm() { |
304 | 301 | global $wgOut, $wgUser, $wgCentralAuthDryRun; |
305 | 302 | |
306 | | - if( $wgCentralAuthDryRun ) { |
| 303 | + if ( $wgCentralAuthDryRun ) { |
307 | 304 | $wgOut->addWikiText( wfMsg( 'centralauth-notice-dryrun' ) ); |
308 | 305 | } |
309 | 306 | |
— | — | @@ -342,7 +339,7 @@ |
343 | 340 | function showStatus( $merged, $remainder ) { |
344 | 341 | global $wgOut; |
345 | 342 | |
346 | | - if( count( $remainder ) > 0 ) { |
| 343 | + if ( count( $remainder ) > 0 ) { |
347 | 344 | $wgOut->setPageTitle( wfMsg( 'centralauth-incomplete' ) ); |
348 | 345 | $wgOut->addWikiText( wfMsg( 'centralauth-incomplete-text' ) ); |
349 | 346 | } else { |
— | — | @@ -351,14 +348,14 @@ |
352 | 349 | } |
353 | 350 | $wgOut->addWikiText( wfMsg( 'centralauth-readmore-text' ) ); |
354 | 351 | |
355 | | - if( $merged ) { |
| 352 | + if ( $merged ) { |
356 | 353 | $wgOut->addHTML( '<hr />' ); |
357 | 354 | $wgOut->addWikiText( wfMsg( 'centralauth-list-attached', |
358 | 355 | $this->mUserName ) ); |
359 | 356 | $wgOut->addHTML( $this->listAttached( $merged ) ); |
360 | 357 | } |
361 | 358 | |
362 | | - if( $remainder ) { |
| 359 | + if ( $remainder ) { |
363 | 360 | $wgOut->addHTML( '<hr />' ); |
364 | 361 | $wgOut->addWikiText( wfMsg( 'centralauth-list-unattached', |
365 | 362 | $this->mUserName ) ); |
— | — | @@ -373,7 +370,7 @@ |
374 | 371 | } |
375 | 372 | } |
376 | 373 | |
377 | | - function listAttached( $wikiList, $methods=array() ) { |
| 374 | + function listAttached( $wikiList, $methods = array() ) { |
378 | 375 | return $this->listWikis( $wikiList, $methods ); |
379 | 376 | } |
380 | 377 | |
— | — | @@ -381,17 +378,17 @@ |
382 | 379 | return $this->listWikis( $wikiList ); |
383 | 380 | } |
384 | 381 | |
385 | | - function listWikis( $list, $methods=array() ) { |
| 382 | + function listWikis( $list, $methods = array() ) { |
386 | 383 | asort( $list ); |
387 | 384 | return $this->formatList( $list, $methods, array( $this, 'listWikiItem' ) ); |
388 | 385 | } |
389 | 386 | |
390 | 387 | function formatList( $items, $methods, $callback ) { |
391 | | - if( !$items ) { |
| 388 | + if ( !$items ) { |
392 | 389 | return ''; |
393 | 390 | } else { |
394 | 391 | $itemMethods = array(); |
395 | | - foreach( $items as $item ) { |
| 392 | + foreach ( $items as $item ) { |
396 | 393 | $itemMethods[] = isset( $methods[$item] ) ? $methods[$item] : ''; |
397 | 394 | } |
398 | 395 | return "<ul>\n<li>" . |
— | — | @@ -408,7 +405,7 @@ |
409 | 406 | |
410 | 407 | function foreignUserLink( $wikiID ) { |
411 | 408 | $wiki = WikiMap::getWiki( $wikiID ); |
412 | | - if( !$wiki ) { |
| 409 | + if ( !$wiki ) { |
413 | 410 | throw new MWException( "no wiki for $wikiID" ); |
414 | 411 | } |
415 | 412 | |
Index: trunk/extensions/CentralAuth/CentralAuthHooks.php |
— | — | @@ -5,7 +5,7 @@ |
6 | 6 | $auth = new StubObject( 'wgAuth', 'CentralAuthPlugin' ); |
7 | 7 | return true; |
8 | 8 | } |
9 | | - |
| 9 | + |
10 | 10 | /** |
11 | 11 | * Make sure migration information in localuser table is populated |
12 | 12 | * on local account creation |
— | — | @@ -15,7 +15,7 @@ |
16 | 16 | $central->addLocalName( wfWikiID() ); |
17 | 17 | return true; |
18 | 18 | } |
19 | | - |
| 19 | + |
20 | 20 | /** |
21 | 21 | * Add a little pretty to the preferences user info section |
22 | 22 | */ |
— | — | @@ -27,7 +27,7 @@ |
28 | 28 | return true; |
29 | 29 | } |
30 | 30 | |
31 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 31 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
32 | 32 | $skin = $wgUser->getSkin(); |
33 | 33 | |
34 | 34 | // Possible states: |
— | — | @@ -37,12 +37,12 @@ |
38 | 38 | // - all local accounts are attached |
39 | 39 | |
40 | 40 | $global = CentralAuthUser::getInstance( $wgUser ); |
41 | | - if( $global->exists() ) { |
42 | | - if( $global->isAttached() ) { |
| 41 | + if ( $global->exists() ) { |
| 42 | + if ( $global->isAttached() ) { |
43 | 43 | // Local is attached... |
44 | 44 | $attached = count( $global->listAttached() ); |
45 | 45 | $unattached = count( $global->listUnattached() ); |
46 | | - if( $unattached ) { |
| 46 | + if ( $unattached ) { |
47 | 47 | // Migration incomplete |
48 | 48 | $message = '<strong>' . wfMsgExt( 'centralauth-prefs-migration', 'parseinline' ) . '</strong>' . |
49 | 49 | '<br />' . |
— | — | @@ -73,7 +73,7 @@ |
74 | 74 | wfMsgExt( 'centralauth-prefs-view', 'parseinline' ) ); |
75 | 75 | $manageLinkList = wfMsg( 'parentheses', $wgLang->pipeList( $manageLinks ) ); |
76 | 76 | |
77 | | - $prefInsert = |
| 77 | + $prefInsert = |
78 | 78 | array( 'globalaccountstatus' => |
79 | 79 | array( |
80 | 80 | 'section' => 'personal/info', |
— | — | @@ -89,30 +89,30 @@ |
90 | 90 | |
91 | 91 | return true; |
92 | 92 | } |
93 | | - |
| 93 | + |
94 | 94 | static function onAbortNewAccount( $user, &$abortError ) { |
95 | 95 | $centralUser = CentralAuthUser::getInstance( $user ); |
96 | 96 | if ( $centralUser->exists() ) { |
97 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 97 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
98 | 98 | $abortError = wfMsg( 'centralauth-account-exists' ); |
99 | 99 | return false; |
100 | 100 | } |
101 | 101 | return true; |
102 | 102 | } |
103 | | - |
| 103 | + |
104 | 104 | static function onUserLoginComplete( &$user, &$inject_html ) { |
105 | 105 | global $wgCentralAuthCookies; |
106 | | - if( !$wgCentralAuthCookies ) { |
| 106 | + if ( !$wgCentralAuthCookies ) { |
107 | 107 | // Use local sessions only. |
108 | 108 | return true; |
109 | 109 | } |
110 | 110 | |
111 | 111 | $centralUser = CentralAuthUser::getInstance( $user ); |
112 | | - |
113 | | - if (!$centralUser->exists() || !$centralUser->isAttached()) { |
| 112 | + |
| 113 | + if ( !$centralUser->exists() || !$centralUser->isAttached() ) { |
114 | 114 | return true; |
115 | 115 | } |
116 | | - |
| 116 | + |
117 | 117 | // On other domains |
118 | 118 | global $wgCentralAuthAutoLoginWikis; |
119 | 119 | if ( !$wgCentralAuthAutoLoginWikis ) { |
— | — | @@ -122,9 +122,9 @@ |
123 | 123 | } |
124 | 124 | |
125 | 125 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
126 | | - $inject_html .= '<div class="centralauth-login-box"><p>' . |
| 126 | + $inject_html .= '<div class="centralauth-login-box"><p>' . |
127 | 127 | wfMsgExt( 'centralauth-login-progress', array( 'parsemag' ), $user->getName() ) . "</p>\n<p>"; |
128 | | - foreach( $wgCentralAuthAutoLoginWikis as $alt => $wiki ) { |
| 128 | + foreach ( $wgCentralAuthAutoLoginWikis as $alt => $wiki ) { |
129 | 129 | $data = array( |
130 | 130 | 'userName' => $user->getName(), |
131 | 131 | 'token' => $centralUser->getAuthToken(), |
— | — | @@ -134,96 +134,97 @@ |
135 | 135 | $loginToken = wfGenerateToken( $centralUser->getId() ); |
136 | 136 | global $wgMemc; |
137 | 137 | $wgMemc->set( CentralAuthUser::memcKey( 'login-token', $loginToken ), $data, 600 ); |
138 | | - |
| 138 | + |
139 | 139 | $wiki = WikiMap::getWiki( $wiki ); |
140 | 140 | $url = $wiki->getUrl( 'Special:AutoLogin' ); |
141 | | - |
| 141 | + |
142 | 142 | $querystring = 'token=' . $loginToken; |
143 | | - |
144 | | - if (strpos($url, '?') > 0) { |
| 143 | + |
| 144 | + if ( strpos( $url, '?' ) > 0 ) { |
145 | 145 | $url .= "&$querystring"; |
146 | 146 | } else { |
147 | 147 | $url .= "?$querystring"; |
148 | 148 | } |
149 | | - |
150 | | - $inject_html .= Xml::element( 'img', |
151 | | - array( |
| 149 | + |
| 150 | + $inject_html .= Xml::element( 'img', |
| 151 | + array( |
152 | 152 | 'src' => $url, |
153 | 153 | 'alt' => $alt, |
154 | 154 | 'title' => $alt, |
155 | 155 | 'width' => 20, |
156 | 156 | 'height' => 20, |
157 | 157 | 'style' => 'border: 1px solid #ccc;', |
158 | | - ) ); |
| 158 | + ) |
| 159 | + ); |
159 | 160 | } |
160 | | - |
| 161 | + |
161 | 162 | $inject_html .= '</p></div>'; |
162 | | - |
| 163 | + |
163 | 164 | return true; |
164 | 165 | } |
165 | | - |
| 166 | + |
166 | 167 | static function onUserLoadFromSession( $user, &$result ) { |
167 | 168 | global $wgCentralAuthCookies, $wgCentralAuthCookiePrefix; |
168 | | - if( !$wgCentralAuthCookies ) { |
| 169 | + if ( !$wgCentralAuthCookies ) { |
169 | 170 | // Use local sessions only. |
170 | 171 | return true; |
171 | 172 | } |
172 | 173 | $prefix = $wgCentralAuthCookiePrefix; |
173 | | - |
174 | | - if( $user->isLoggedIn() ) { |
| 174 | + |
| 175 | + if ( $user->isLoggedIn() ) { |
175 | 176 | // Already logged in; don't worry about the global session. |
176 | 177 | return true; |
177 | 178 | } |
178 | | - |
179 | | - if (isset($_COOKIE["{$prefix}User"]) && isset($_COOKIE["{$prefix}Token"])) { |
| 179 | + |
| 180 | + if ( isset( $_COOKIE["{$prefix}User"] ) && isset( $_COOKIE["{$prefix}Token"] ) ) { |
180 | 181 | $userName = $_COOKIE["{$prefix}User"]; |
181 | 182 | $token = $_COOKIE["{$prefix}Token"]; |
182 | 183 | } elseif ( (bool)( $session = CentralAuthUser::getSession() ) ) { |
183 | 184 | $token = $session['token']; |
184 | 185 | $userName = $session['user']; |
185 | 186 | } else { |
186 | | - wfDebug( __METHOD__.": no token or session\n" ); |
| 187 | + wfDebug( __METHOD__ . ": no token or session\n" ); |
187 | 188 | return true; |
188 | 189 | } |
189 | | - |
| 190 | + |
190 | 191 | // Sanity check to avoid session ID collisions, as reported on bug 19158 |
191 | | - if ( !isset($_COOKIE["{$prefix}User"]) ) { |
192 | | - wfDebug( __METHOD__.": no User cookie, so unable to check for session mismatch\n" ); |
| 192 | + if ( !isset( $_COOKIE["{$prefix}User"] ) ) { |
| 193 | + wfDebug( __METHOD__ . ": no User cookie, so unable to check for session mismatch\n" ); |
193 | 194 | return true; |
194 | 195 | } elseif ( $_COOKIE["{$prefix}User"] != $userName ) { |
195 | | - wfDebug( __METHOD__.": Session ID/User mismatch. Possible session collision. ". |
196 | | - "Expected: $userName; actual: ". |
197 | | - $_COOKIE["{$prefix}User"]."\n" ); |
| 196 | + wfDebug( __METHOD__ . ": Session ID/User mismatch. Possible session collision. " . |
| 197 | + "Expected: $userName; actual: " . |
| 198 | + $_COOKIE["{$prefix}User"] . "\n" ); |
198 | 199 | return true; |
199 | 200 | } |
200 | 201 | |
201 | 202 | // Clean up username |
202 | 203 | $title = Title::makeTitleSafe( NS_USER, $userName ); |
203 | 204 | if ( !$title ) { |
204 | | - wfDebug( __METHOD__.": invalid username\n" ); |
| 205 | + wfDebug( __METHOD__ . ": invalid username\n" ); |
205 | 206 | } |
206 | 207 | $userName = $title->getText(); |
207 | 208 | |
208 | 209 | // Try the central user |
209 | 210 | $centralUser = new CentralAuthUser( $userName ); |
210 | 211 | if ( $centralUser->authenticateWithToken( $token ) != 'ok' ) { |
211 | | - wfDebug( __METHOD__.": token mismatch\n" ); |
| 212 | + wfDebug( __METHOD__ . ": token mismatch\n" ); |
212 | 213 | return true; |
213 | 214 | } |
214 | 215 | |
215 | 216 | // Try the local user from the slave DB |
216 | 217 | $localId = User::idFromName( $userName ); |
217 | 218 | |
218 | | - // Fetch the user ID from the master, so that we don't try to create the user |
| 219 | + // Fetch the user ID from the master, so that we don't try to create the user |
219 | 220 | // when they already exist, due to replication lag |
220 | 221 | if ( !$localId && wfGetLB()->getReaderIndex() != 0 ) { |
221 | 222 | $dbw = wfGetDB( DB_MASTER ); |
222 | | - $localId = $dbw->selectField( 'user', 'user_id', |
| 223 | + $localId = $dbw->selectField( 'user', 'user_id', |
223 | 224 | array( 'user_name' => $userName ), __METHOD__ ); |
224 | 225 | } |
225 | 226 | |
226 | 227 | if ( !$centralUser->isAttached() && $localId ) { |
227 | | - wfDebug( __METHOD__.": exists, and not attached\n" ); |
| 228 | + wfDebug( __METHOD__ . ": exists, and not attached\n" ); |
228 | 229 | return true; |
229 | 230 | } |
230 | 231 | |
— | — | @@ -237,34 +238,35 @@ |
238 | 239 | $user->setID( $localId ); |
239 | 240 | $user->loadFromId(); |
240 | 241 | } |
| 242 | + |
241 | 243 | // Auth OK. |
242 | | - wfDebug( __METHOD__.": logged in from session\n" ); |
| 244 | + wfDebug( __METHOD__ . ": logged in from session\n" ); |
243 | 245 | self::initSession( $user, $token ); |
244 | 246 | $user->centralAuthObj = $centralUser; |
245 | 247 | $result = true; |
246 | | - |
| 248 | + |
247 | 249 | return true; |
248 | 250 | } |
249 | | - |
| 251 | + |
250 | 252 | static function onUserLogout( &$user ) { |
251 | 253 | global $wgCentralAuthCookies; |
252 | | - if( !$wgCentralAuthCookies ) { |
| 254 | + if ( !$wgCentralAuthCookies ) { |
253 | 255 | // Use local sessions only. |
254 | 256 | return true; |
255 | 257 | } |
256 | 258 | $centralUser = CentralAuthUser::getInstance( $user ); |
257 | | - |
258 | | - if ($centralUser->exists()) { |
| 259 | + |
| 260 | + if ( $centralUser->exists() ) { |
259 | 261 | $centralUser->deleteGlobalCookies(); |
260 | 262 | $centralUser->resetAuthToken(); |
261 | 263 | } |
262 | | - |
| 264 | + |
263 | 265 | return true; |
264 | 266 | } |
265 | | - |
| 267 | + |
266 | 268 | static function onUserLogoutComplete( &$user, &$inject_html, $userName ) { |
267 | 269 | global $wgCentralAuthCookies, $wgCentralAuthAutoLoginWikis; |
268 | | - if( !$wgCentralAuthCookies ) { |
| 270 | + if ( !$wgCentralAuthCookies ) { |
269 | 271 | // Nothing to do. |
270 | 272 | return true; |
271 | 273 | } elseif ( !$wgCentralAuthAutoLoginWikis ) { |
— | — | @@ -272,10 +274,10 @@ |
273 | 275 | $inject_html .= wfMsgExt( 'centralauth-logout-no-others', 'parse' ); |
274 | 276 | return true; |
275 | 277 | } |
276 | | - |
| 278 | + |
277 | 279 | $centralUser = CentralAuthUser::getInstance( $user ); |
278 | | - |
279 | | - if (!$centralUser->exists() || !$centralUser->isAttached()) { |
| 280 | + |
| 281 | + if ( !$centralUser->exists() || !$centralUser->isAttached() ) { |
280 | 282 | return true; |
281 | 283 | } elseif ( !$wgCentralAuthAutoLoginWikis ) { |
282 | 284 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
— | — | @@ -285,11 +287,11 @@ |
286 | 288 | |
287 | 289 | // Generate the images |
288 | 290 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
289 | | - $inject_html .= '<div class="centralauth-logout-box"><p>' . |
| 291 | + $inject_html .= '<div class="centralauth-logout-box"><p>' . |
290 | 292 | wfMsg( 'centralauth-logout-progress' ) . "</p>\n<p>"; |
291 | 293 | $centralUser = new CentralAuthUser( $userName ); |
292 | 294 | |
293 | | - foreach( $wgCentralAuthAutoLoginWikis as $alt => $wiki ) { |
| 295 | + foreach ( $wgCentralAuthAutoLoginWikis as $alt => $wiki ) { |
294 | 296 | $data = array( |
295 | 297 | 'userName' => $userName, |
296 | 298 | 'token' => $centralUser->getAuthToken(), |
— | — | @@ -302,28 +304,29 @@ |
303 | 305 | |
304 | 306 | $wiki = WikiMap::getWiki( $wiki ); |
305 | 307 | $url = $wiki->getUrl( 'Special:AutoLogin' ); |
306 | | - |
307 | | - if (strpos($url, '?') > 0) { |
| 308 | + |
| 309 | + if ( strpos( $url, '?' ) > 0 ) { |
308 | 310 | $url .= "&logout=1&token=$loginToken"; |
309 | 311 | } else { |
310 | 312 | $url .= "?logout=1&token=$loginToken"; |
311 | 313 | } |
312 | | - |
313 | | - $inject_html .= Xml::element( 'img', |
314 | | - array( |
| 314 | + |
| 315 | + $inject_html .= Xml::element( 'img', |
| 316 | + array( |
315 | 317 | 'src' => $url, |
316 | 318 | 'alt' => $alt, |
317 | 319 | 'title' => $alt, |
318 | 320 | 'width' => 20, |
319 | 321 | 'height' => 20, |
320 | 322 | 'style' => 'border: 1px solid #ccc;', |
321 | | - ) ); |
| 323 | + ) |
| 324 | + ); |
322 | 325 | } |
323 | | - |
| 326 | + |
324 | 327 | $inject_html .= '</p></div>'; |
325 | 328 | return true; |
326 | 329 | } |
327 | | - |
| 330 | + |
328 | 331 | static function onGetCacheVaryCookies( $out, &$cookies ) { |
329 | 332 | global $wgCentralAuthCookiePrefix; |
330 | 333 | $cookies[] = $wgCentralAuthCookiePrefix . 'Token'; |
— | — | @@ -331,24 +334,24 @@ |
332 | 335 | $cookies[] = $wgCentralAuthCookiePrefix . 'LoggedOut'; |
333 | 336 | return true; |
334 | 337 | } |
335 | | - |
| 338 | + |
336 | 339 | static function onUserArrayFromResult( &$userArray, $res ) { |
337 | 340 | $userArray = CentralAuthUserArray::newFromResult( $res ); |
338 | 341 | return true; |
339 | 342 | } |
340 | | - |
| 343 | + |
341 | 344 | /** |
342 | 345 | * Warn bureaucrat about possible conflicts with unified accounts |
343 | 346 | */ |
344 | 347 | static function onRenameUserWarning( $oldName, $newName, &$warnings ) { |
345 | 348 | $oldCentral = new CentralAuthUser( $oldName ); |
346 | 349 | if ( $oldCentral->exists() && $oldCentral->isAttached() ) { |
347 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 350 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
348 | 351 | $warnings[] = array( 'centralauth-renameuser-merged', $oldName, $newName ); |
349 | 352 | } |
350 | 353 | $newCentral = new CentralAuthUser( $newName ); |
351 | 354 | if ( $newCentral->exists() && !$newCentral->isAttached() ) { |
352 | | - wfLoadExtensionMessages('SpecialCentralAuth'); |
| 355 | + wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
353 | 356 | $warnings[] = array( 'centralauth-renameuser-reserved', $oldName, $newName ); |
354 | 357 | } |
355 | 358 | return true; |
— | — | @@ -356,7 +359,7 @@ |
357 | 360 | |
358 | 361 | static function onRenameUserPreRename( $uid, $oldName, $newName ) { |
359 | 362 | $oldCentral = new CentralAuthUser( $oldName ); |
360 | | - if( $oldCentral->exists() && $oldCentral->isAttached() ) { |
| 363 | + if ( $oldCentral->exists() && $oldCentral->isAttached() ) { |
361 | 364 | $oldCentral->adminUnattach( array( wfWikiID() ) ); |
362 | 365 | } |
363 | 366 | return true; |
— | — | @@ -383,14 +386,14 @@ |
384 | 387 | |
385 | 388 | $userName = $user->getName(); |
386 | 389 | wfSetupSession(); |
387 | | - if ($token != @$_SESSION['globalloggedin'] ) { |
| 390 | + if ( $token != @$_SESSION['globalloggedin'] ) { |
388 | 391 | $_SESSION['globalloggedin'] = $token; |
389 | 392 | if ( !wfReadOnly() ) { |
390 | 393 | $user->invalidateCache(); |
391 | 394 | } |
392 | | - wfDebug( __METHOD__.": Initialising session for $userName with token $token.\n" ); |
| 395 | + wfDebug( __METHOD__ . ": Initialising session for $userName with token $token.\n" ); |
393 | 396 | } else { |
394 | | - wfDebug( __METHOD__.": Session already initialised for $userName with token $token.\n" ); |
| 397 | + wfDebug( __METHOD__ . ": Session already initialised for $userName with token $token.\n" ); |
395 | 398 | } |
396 | 399 | } |
397 | 400 | |
— | — | @@ -404,24 +407,24 @@ |
405 | 408 | global $wgAuth, $wgCentralAuthCreateOnView; |
406 | 409 | // Denied by configuration? |
407 | 410 | if ( !$wgAuth->autoCreate() ) { |
408 | | - wfDebug( __METHOD__.": denied by configuration\n" ); |
| 411 | + wfDebug( __METHOD__ . ": denied by configuration\n" ); |
409 | 412 | return false; |
410 | 413 | } |
411 | | - |
| 414 | + |
412 | 415 | if ( !$wgCentralAuthCreateOnView ) { |
413 | 416 | // Only create local accounts when we perform an active login... |
414 | 417 | // Don't freak people out on every page view |
415 | | - wfDebug( __METHOD__.": denied by \$wgCentralAuthCreateOnView\n" ); |
| 418 | + wfDebug( __METHOD__ . ": denied by \$wgCentralAuthCreateOnView\n" ); |
416 | 419 | return false; |
417 | 420 | } |
418 | 421 | |
419 | 422 | // Is the user blacklisted by the session? |
420 | | - // This is just a cache to avoid expensive DB queries in $user->isAllowedToCreateAccount(). |
421 | | - // The user can log in via Special:UserLogin to bypass the blacklist and get a proper |
| 423 | + // This is just a cache to avoid expensive DB queries in $user->isAllowedToCreateAccount(). |
| 424 | + // The user can log in via Special:UserLogin to bypass the blacklist and get a proper |
422 | 425 | // error message. |
423 | 426 | $session = CentralAuthUser::getSession(); |
424 | 427 | if ( isset( $session['auto-create-blacklist'] ) && in_array( wfWikiID(), (array)$session['auto-create-blacklist'] ) ) { |
425 | | - wfDebug( __METHOD__.": blacklisted by session\n" ); |
| 428 | + wfDebug( __METHOD__ . ": blacklisted by session\n" ); |
426 | 429 | return false; |
427 | 430 | } |
428 | 431 | |
— | — | @@ -430,24 +433,24 @@ |
431 | 434 | if ( !$anon->isAllowedToCreateAccount() ) { |
432 | 435 | // Blacklist the user to avoid repeated DB queries subsequently |
433 | 436 | // First load the session again in case it changed while the above DB query was in progress |
434 | | - wfDebug( __METHOD__.": user is blocked from this wiki, blacklisting\n" ); |
| 437 | + wfDebug( __METHOD__ . ": user is blocked from this wiki, blacklisting\n" ); |
435 | 438 | $session = CentralAuthUser::getSession(); |
436 | 439 | $session['auto-create-blacklist'][] = wfWikiID(); |
437 | 440 | CentralAuthUser::setSession( $session ); |
438 | 441 | return false; |
439 | 442 | } |
440 | 443 | |
441 | | - // Check for validity of username |
442 | | - if ( !User::isValidUserName( $userName ) ) { |
443 | | - wfDebug( __METHOD__.": Invalid username\n" ); |
444 | | - $session = CentralAuthUser::getSession(); |
445 | | - $session['auto-create-blacklist'][] = wfWikiID(); |
446 | | - CentralAuthUser::setSession( $session ); |
447 | | - return false; |
448 | | - } |
| 444 | + // Check for validity of username |
| 445 | + if ( !User::isValidUserName( $userName ) ) { |
| 446 | + wfDebug( __METHOD__ . ": Invalid username\n" ); |
| 447 | + $session = CentralAuthUser::getSession(); |
| 448 | + $session['auto-create-blacklist'][] = wfWikiID(); |
| 449 | + CentralAuthUser::setSession( $session ); |
| 450 | + return false; |
| 451 | + } |
449 | 452 | |
450 | 453 | // Checks passed, create the user |
451 | | - wfDebug( __METHOD__.": creating new user\n" ); |
| 454 | + wfDebug( __METHOD__ . ": creating new user\n" ); |
452 | 455 | $user->loadDefaults( $userName ); |
453 | 456 | $user->addToDatabase(); |
454 | 457 | $user->addNewUserLogEntryAutoCreate(); |
— | — | @@ -461,7 +464,7 @@ |
462 | 465 | # Update user count |
463 | 466 | $ssUpdate = new SiteStatsUpdate( 0, 0, 0, 0, 1 ); |
464 | 467 | $ssUpdate->doUpdate(); |
465 | | - |
| 468 | + |
466 | 469 | return true; |
467 | 470 | } |
468 | 471 | |
— | — | @@ -504,26 +507,26 @@ |
505 | 508 | } |
506 | 509 | return true; |
507 | 510 | } |
508 | | - |
| 511 | + |
509 | 512 | static function onUserGetRights( $user, &$rights ) { |
510 | | - if (!$user->isAnon()) { |
| 513 | + if ( !$user->isAnon() ) { |
511 | 514 | $centralUser = CentralAuthUser::getInstance( $user ); |
512 | | - |
513 | | - if ($centralUser->exists() && $centralUser->isAttached()) { |
| 515 | + |
| 516 | + if ( $centralUser->exists() && $centralUser->isAttached() ) { |
514 | 517 | $extraRights = $centralUser->getGlobalRights(); |
515 | | - |
| 518 | + |
516 | 519 | $rights = array_merge( $extraRights, $rights ); |
517 | 520 | } |
518 | 521 | } |
519 | | - |
| 522 | + |
520 | 523 | return true; |
521 | 524 | } |
522 | | - |
| 525 | + |
523 | 526 | static function onMakeGlobalVariablesScript( $groups ) { |
524 | 527 | global $wgUser; |
525 | 528 | if ( !$wgUser->isAnon() ) { |
526 | 529 | $centralUser = CentralAuthUser::getInstance( $wgUser ); |
527 | | - if ($centralUser->exists() && $centralUser->isAttached()) { |
| 530 | + if ( $centralUser->exists() && $centralUser->isAttached() ) { |
528 | 531 | $groups['wgGlobalGroups'] = $centralUser->getGlobalGroups(); |
529 | 532 | } |
530 | 533 | } |
— | — | @@ -559,8 +562,8 @@ |
560 | 563 | */ |
561 | 564 | static function onUserLoadDefaults( $user, $name ) { |
562 | 565 | global $wgCentralAuthCookiePrefix; |
563 | | - if ( isset( $_COOKIE[$wgCentralAuthCookiePrefix.'LoggedOut'] ) ) { |
564 | | - $user->mTouched = wfTimestamp( TS_MW, $_COOKIE[$wgCentralAuthCookiePrefix.'LoggedOut'] ); |
| 566 | + if ( isset( $_COOKIE[$wgCentralAuthCookiePrefix . 'LoggedOut'] ) ) { |
| 567 | + $user->mTouched = wfTimestamp( TS_MW, $_COOKIE[$wgCentralAuthCookiePrefix . 'LoggedOut'] ); |
565 | 568 | } |
566 | 569 | return true; |
567 | 570 | } |
— | — | @@ -568,14 +571,14 @@ |
569 | 572 | static function onGetUserPermissionsErrorsExpensive( $title, $user, $action, &$result ) { |
570 | 573 | global $wgCentralAuthLockedCanEdit; |
571 | 574 | |
572 | | - if( $action == 'read' || $user->isAnon() ) { |
| 575 | + if ( $action == 'read' || $user->isAnon() ) { |
573 | 576 | return true; |
574 | 577 | } |
575 | 578 | $centralUser = CentralAuthUser::getInstance( $user ); |
576 | | - if( !($centralUser->exists() && $centralUser->isAttached()) ) { |
| 579 | + if ( !( $centralUser->exists() && $centralUser->isAttached() ) ) { |
577 | 580 | return true; |
578 | 581 | } |
579 | | - if( |
| 582 | + if ( |
580 | 583 | $centralUser->isOversighted() || // Oversighted users should *never* be able to edit |
581 | 584 | ( $centralUser->isLocked() && !in_array( $title->getPrefixedText(), $wgCentralAuthLockedCanEdit ) ) |
582 | 585 | ) { |
— | — | @@ -590,7 +593,7 @@ |
591 | 594 | return true; |
592 | 595 | } |
593 | 596 | $centralUser = CentralAuthUser::getInstance( $user ); |
594 | | - if( !($centralUser->exists() && $centralUser->isAttached()) ) { |
| 597 | + if ( !( $centralUser->exists() && $centralUser->isAttached() ) ) { |
595 | 598 | return true; |
596 | 599 | } |
597 | 600 | $wikiID = $centralUser->getHomeWiki(); |
Index: trunk/extensions/CentralAuth/SuppressUserJob.php |
— | — | @@ -15,7 +15,7 @@ |
16 | 16 | public function __construct( $title, $params ) { |
17 | 17 | parent::__construct( 'crosswikiSuppressUser', $title, $params ); |
18 | 18 | } |
19 | | - |
| 19 | + |
20 | 20 | /** |
21 | 21 | * Execute the job |
22 | 22 | * |
— | — | @@ -24,11 +24,11 @@ |
25 | 25 | public function run() { |
26 | 26 | extract( $this->params ); |
27 | 27 | $user = new CentralAuthUser( $username ); |
28 | | - if( !$user->exists() ) { |
| 28 | + if ( !$user->exists() ) { |
29 | 29 | wfDebugLog( 'suppressjob', "Requested to suppress non-existent user {$username} by {$by}." ); |
30 | 30 | } |
31 | 31 | |
32 | | - foreach( $wikis as $wiki ) { |
| 32 | + foreach ( $wikis as $wiki ) { |
33 | 33 | $user->doLocalSuppression( $suppress, $wiki, $by, $reason ); |
34 | 34 | wfDebugLog( 'suppressjob', ( $suppress ? 'S' : 'Uns' ) . "uppressed {$username} at {$wiki} by {$by} via job queue." ); |
35 | 35 | } |
Index: trunk/extensions/CentralAuth/WikiSet.php |
— | — | @@ -36,20 +36,24 @@ |
37 | 37 | public function setWikisRaw( $w, $commit = false ) { return $this->setDbField( 'ws_wikis', $w, $commit ); } |
38 | 38 | public function getType() { return $this->mType; } |
39 | 39 | public function setType( $t, $commit = false ) { |
40 | | - if( !in_array( $t, array( self::OPTIN, self::OPTOUT ) ) ) |
| 40 | + if ( !in_array( $t, array( self::OPTIN, self::OPTOUT ) ) ) { |
41 | 41 | return false; |
| 42 | + } |
42 | 43 | return $this->setDbField( 'ws_type', $t, $commit ); |
43 | 44 | } |
44 | 45 | protected function setDbField( $field, $value, $commit ) { |
45 | 46 | $map = array( 'ws_name' => 'mName', 'ws_type' => 'mType', 'ws_wikis' => 'mWikis' ); |
46 | 47 | $mname = $map[$field]; |
47 | 48 | $this->$mname = $value; |
48 | | - if( $commit ) |
| 49 | + if ( $commit ) { |
49 | 50 | $this->commit(); |
| 51 | + } |
50 | 52 | } |
51 | 53 | |
52 | 54 | public static function newFromRow( $row ) { |
53 | | - if( !$row ) return null; |
| 55 | + if ( !$row ) { |
| 56 | + return null; |
| 57 | + } |
54 | 58 | return new WikiSet( |
55 | 59 | $row->ws_name, |
56 | 60 | $row->ws_type, |
— | — | @@ -59,13 +63,13 @@ |
60 | 64 | } |
61 | 65 | |
62 | 66 | public static function newFromName( $name, $useCache = true ) { |
63 | | - if( $useCache ) { |
| 67 | + if ( $useCache ) { |
64 | 68 | global $wgMemc; |
65 | 69 | $data = $wgMemc->get( self::memcKey( "name:" . md5( $name ) ) ); |
66 | | - if( $data ) { |
67 | | - if( $data['mVersion'] == self::VERSION ) { |
| 70 | + if ( $data ) { |
| 71 | + if ( $data['mVersion'] == self::VERSION ) { |
68 | 72 | $ws = new WikiSet( null, null, null ); |
69 | | - foreach( $data as $key => $val ) |
| 73 | + foreach ( $data as $key => $val ) |
70 | 74 | $ws->$key = $val; |
71 | 75 | return $ws; |
72 | 76 | } |
— | — | @@ -75,21 +79,22 @@ |
76 | 80 | $row = $dbr->selectRow( |
77 | 81 | 'wikiset', '*', array( 'ws_name' => $name ), __METHOD__ |
78 | 82 | ); |
79 | | - if( !$row ) |
| 83 | + if ( !$row ) { |
80 | 84 | return null; |
| 85 | + } |
81 | 86 | $ws = self::newFromRow( $row ); |
82 | 87 | $ws->saveToCache(); |
83 | 88 | return $ws; |
84 | 89 | } |
85 | 90 | |
86 | 91 | public static function newFromID( $id, $useCache = true ) { |
87 | | - if( $useCache ) { |
| 92 | + if ( $useCache ) { |
88 | 93 | global $wgMemc; |
89 | 94 | $data = $wgMemc->get( self::memcKey( $id ) ); |
90 | | - if( $data ) { |
91 | | - if( $data['mVersion'] == self::VERSION ) { |
| 95 | + if ( $data ) { |
| 96 | + if ( $data['mVersion'] == self::VERSION ) { |
92 | 97 | $ws = new WikiSet( null, null, null ); |
93 | | - foreach( $data as $name => $val ) |
| 98 | + foreach ( $data as $name => $val ) |
94 | 99 | $ws->$name = $val; |
95 | 100 | return $ws; |
96 | 101 | } |
— | — | @@ -99,8 +104,9 @@ |
100 | 105 | $row = $dbr->selectRow( |
101 | 106 | 'wikiset', '*', array( 'ws_id' => $id ), __METHOD__ |
102 | 107 | ); |
103 | | - if( !$row ) |
| 108 | + if ( !$row ) { |
104 | 109 | return null; |
| 110 | + } |
105 | 111 | $ws = self::newFromRow( $row ); |
106 | 112 | $ws->saveToCache(); |
107 | 113 | return $ws; |
— | — | @@ -117,8 +123,9 @@ |
118 | 124 | ), __METHOD__ |
119 | 125 | ); |
120 | 126 | $dbw->commit(); |
121 | | - if( !$this->mId ) |
| 127 | + if ( !$this->mId ) { |
122 | 128 | $this->mId = $dbw->insertId(); |
| 129 | + } |
123 | 130 | $this->purge(); |
124 | 131 | return (bool)$dbw->affectedRows(); |
125 | 132 | } |
— | — | @@ -140,22 +147,24 @@ |
141 | 148 | public function saveToCache() { |
142 | 149 | global $wgMemc; |
143 | 150 | $data = array(); |
144 | | - foreach( self::$mCacheVars as $var ) { |
| 151 | + foreach ( self::$mCacheVars as $var ) { |
145 | 152 | $data[$var] = $this->$var; |
146 | 153 | } |
147 | 154 | $wgMemc->set( self::memcKey( $this->mId ), $data ); |
148 | 155 | } |
149 | 156 | |
150 | 157 | public function getWikis() { |
151 | | - if( $this->mType == self::OPTIN ) |
| 158 | + if ( $this->mType == self::OPTIN ) { |
152 | 159 | return $this->mWikis; |
| 160 | + } |
153 | 161 | else |
154 | 162 | return array_diff( CentralAuthUser::getWikiList(), $this->mWikis ); |
155 | 163 | } |
156 | 164 | |
157 | 165 | public function inSet( $wiki = '' ) { |
158 | | - if( !$wiki ) |
| 166 | + if ( !$wiki ) { |
159 | 167 | $wiki = wfWikiID(); |
| 168 | + } |
160 | 169 | return in_array( $wiki, $this->getWikis() ); |
161 | 170 | } |
162 | 171 | |
— | — | @@ -165,8 +174,9 @@ |
166 | 175 | 'global_group_restrictions', '*', array( 'ggr_set' => $this->mId ), __METHOD__ |
167 | 176 | ); |
168 | 177 | $result = array(); |
169 | | - foreach( $r as $row ) |
| 178 | + foreach ( $r as $row ) { |
170 | 179 | $result[] = $row->ggr_group; |
| 180 | + } |
171 | 181 | return $result; |
172 | 182 | } |
173 | 183 | |
— | — | @@ -174,8 +184,9 @@ |
175 | 185 | $dbr = CentralAuthUser::getCentralSlaveDB(); |
176 | 186 | $res = $dbr->select( 'wikiset', '*', false, __METHOD__ ); |
177 | 187 | $result = array(); |
178 | | - while( $row = $dbr->fetchObject( $res ) ) |
| 188 | + while ( $row = $dbr->fetchObject( $res ) ) { |
179 | 189 | $result[] = self::newFromRow( $row ); |
| 190 | + } |
180 | 191 | return $result; |
181 | 192 | } |
182 | 193 | |
Index: trunk/extensions/CentralAuth/SpecialGlobalUsers.php |
— | — | @@ -1,7 +1,6 @@ |
2 | 2 | <?php |
3 | 3 | |
4 | 4 | class SpecialGlobalUsers extends SpecialPage { |
5 | | - |
6 | 5 | function __construct() { |
7 | 6 | wfLoadExtensionMessages( 'SpecialCentralAuth' ); |
8 | 7 | parent::__construct( 'GlobalUsers' ); |
— | — | @@ -13,13 +12,13 @@ |
14 | 13 | |
15 | 14 | $pg = new GlobalUsersPager(); |
16 | 15 | |
17 | | - if( $par ) { |
| 16 | + if ( $par ) { |
18 | 17 | $pg->setGroup( $par ); |
19 | 18 | } |
20 | | - if( $rqGroup = $wgRequest->getVal( 'group' ) ) { |
| 19 | + if ( $rqGroup = $wgRequest->getVal( 'group' ) ) { |
21 | 20 | $pg->setGroup( $rqGroup ); |
22 | 21 | } |
23 | | - if( $rqUsername = $wgContLang->ucfirst( $wgRequest->getVal( 'username' ) ) ) { |
| 22 | + if ( $rqUsername = $wgContLang->ucfirst( $wgRequest->getVal( 'username' ) ) ) { |
24 | 23 | $pg->setUsername( $rqUsername ); |
25 | 24 | } |
26 | 25 | |
— | — | @@ -39,12 +38,12 @@ |
40 | 39 | } |
41 | 40 | |
42 | 41 | function setGroup( $group = '' ) { |
43 | | - if( !$group ) { |
| 42 | + if ( !$group ) { |
44 | 43 | $this->mGroup = false; |
45 | 44 | return; |
46 | 45 | } |
47 | 46 | $groups = array_keys( $this->getAllGroups() ); |
48 | | - if( in_array( $group, $groups ) ) { |
| 47 | + if ( in_array( $group, $groups ) ) { |
49 | 48 | $this->mGroup = $group; |
50 | 49 | } else { |
51 | 50 | $this->mGroup = false; |
— | — | @@ -52,7 +51,7 @@ |
53 | 52 | } |
54 | 53 | |
55 | 54 | function setUsername( $username = '' ) { |
56 | | - if( !$username ) { |
| 55 | + if ( !$username ) { |
57 | 56 | $this->mUsername = false; |
58 | 57 | return; |
59 | 58 | } |
— | — | @@ -65,8 +64,9 @@ |
66 | 65 | |
67 | 66 | function getDefaultQuery() { |
68 | 67 | $query = parent::getDefaultQuery(); |
69 | | - if( !isset( $query['group'] ) && $this->mGroup ) |
| 68 | + if ( !isset( $query['group'] ) && $this->mGroup ) { |
70 | 69 | $query['group'] = $this->mGroup; |
| 70 | + } |
71 | 71 | return $this->mDefaultQuery = $query; |
72 | 72 | |
73 | 73 | } |
— | — | @@ -75,11 +75,13 @@ |
76 | 76 | $localwiki = wfWikiID(); |
77 | 77 | $conds = array( 'gu_hidden' => CentralAuthUser::HIDDEN_NONE ); |
78 | 78 | |
79 | | - if( $this->mGroup ) |
| 79 | + if ( $this->mGroup ) { |
80 | 80 | $conds['gug_group'] = $this->mGroup; |
| 81 | + } |
81 | 82 | |
82 | | - if( $this->mUsername ) |
| 83 | + if ( $this->mUsername ) { |
83 | 84 | $conds[] = 'gu_name >= ' . $this->mDb->addQuotes( $this->mUsername ); |
| 85 | + } |
84 | 86 | |
85 | 87 | return array( |
86 | 88 | 'tables' => " (globaluser LEFT JOIN localuser ON gu_name = lu_name AND lu_wiki = '{$localwiki}') LEFT JOIN global_user_groups ON gu_id = gug_user ", |
— | — | @@ -98,9 +100,10 @@ |
99 | 101 | global $wgLang; |
100 | 102 | $user = htmlspecialchars( $row->gu_name ); |
101 | 103 | $info = array(); |
102 | | - if( $row->gu_locked ) |
| 104 | + if ( $row->gu_locked ) { |
103 | 105 | $info[] = wfMsgHtml( 'centralauth-listusers-locked' ); |
104 | | - if( $row->lu_attached_method ) { |
| 106 | + } |
| 107 | + if ( $row->lu_attached_method ) { |
105 | 108 | $userPage = Title::makeTitle( NS_USER, $row->gu_name ); |
106 | 109 | $text = wfMsgHtml( 'centralauth-listusers-attached' ); |
107 | 110 | $info[] = $this->getSkin()->makeLinkObj( $userPage, $text ); |
— | — | @@ -108,7 +111,7 @@ |
109 | 112 | $info[] = wfMsgHtml( 'centralauth-listusers-nolocal' ); |
110 | 113 | } |
111 | 114 | $groups = $this->getUserGroups( $row ); |
112 | | - if( $groups ) { |
| 115 | + if ( $groups ) { |
113 | 116 | $info[] = $groups; |
114 | 117 | } |
115 | 118 | $info = $wgLang->commaList( $info ); |
— | — | @@ -116,7 +119,7 @@ |
117 | 120 | } |
118 | 121 | |
119 | 122 | function getBody() { |
120 | | - if (!$this->mQueryDone) { |
| 123 | + if ( !$this->mQueryDone ) { |
121 | 124 | $this->doQuery(); |
122 | 125 | } |
123 | 126 | $batch = new LinkBatch; |
— | — | @@ -132,21 +135,23 @@ |
133 | 136 | } |
134 | 137 | |
135 | 138 | function getUserGroups( $row ) { |
136 | | - if( !$row->gug_numgroups ) |
| 139 | + if ( !$row->gug_numgroups ) { |
137 | 140 | return false; |
138 | | - if( $row->gug_numgroups == 1 ) { |
| 141 | + } |
| 142 | + if ( $row->gug_numgroups == 1 ) { |
139 | 143 | return self::buildGroupLink( $row->gug_singlegroup ); |
140 | 144 | } |
141 | 145 | $result = $this->mDb->select( 'global_user_groups', 'gug_group', array( 'gug_user' => $row->gu_id ), __METHOD__ ); |
142 | 146 | $rights = array(); |
143 | | - while( $row2 = $this->mDb->fetchObject( $result ) ) |
| 147 | + while ( $row2 = $this->mDb->fetchObject( $result ) ) { |
144 | 148 | $rights[] = self::buildGroupLink( $row2->gug_group ); |
| 149 | + } |
145 | 150 | return implode( ', ', $rights ); |
146 | 151 | } |
147 | 152 | |
148 | 153 | function getAllGroups() { |
149 | 154 | $result = array(); |
150 | | - foreach( CentralAuthUser::availableGlobalGroups() as $group ) { |
| 155 | + foreach ( CentralAuthUser::availableGlobalGroups() as $group ) { |
151 | 156 | $result[$group] = User::getGroupName( $group ); |
152 | 157 | } |
153 | 158 | return $result; |
Index: trunk/extensions/CentralAuth/CentralAuth.i18n.php |
— | — | @@ -623,7 +623,7 @@ |
624 | 624 | Si bel usuario más ha pillato o suyo nombre d'usuario en atro sitio, podrá contautar con el u con un almenistrador más entadebant.", |
625 | 625 | 'centralauth-merge-step1-title' => 'Prenzipiar a unificazión de cuentas', |
626 | 626 | 'centralauth-merge-step1-detail' => "Por fabor, escriba aquí a suya palabra de paso. |
627 | | -A suya palabra de paso y adreza de correu-e rechistrada se comprebarán con as d'atras wikis ta confirmar si concuerdan. |
| 627 | +A suya palabra de paso y adreza de correu-e rechistrada se comprebarán con as d'atras wikis ta confirmar si concuerdan. |
628 | 628 | No se ferá garra cambio dica que confirme que to pareix conforme.", |
629 | 629 | 'centralauth-merge-step1-submit' => "Confirmar a informazión d'a cuenta", |
630 | 630 | 'centralauth-merge-step2-title' => 'Confirmar más cuentas', |
— | — | @@ -632,7 +632,7 @@ |
633 | 633 | 'centralauth-merge-dryrun-complete' => "Todas as cuentas esistents pueden unificar-se automaticament! |
634 | 634 | |
635 | 635 | Encara no s'han feito cambios t'as cuentas", |
636 | | - 'centralauth-merge-dryrun-incomplete' => "Puede continar, pero bellas cuentas no s'han puesto comprebar y por ixo no se migrarán contino. Podrá combinar istas cuentas dimpués. |
| 636 | + 'centralauth-merge-dryrun-incomplete' => "Puede continar, pero bellas cuentas no s'han puesto comprebar y por ixo no se migrarán contino. Podrá combinar istas cuentas dimpués. |
637 | 637 | |
638 | 638 | Encara no s'han feito cambios t'as suyas cuentas.", |
639 | 639 | 'centralauth-merge-dryrun-or' => "'''u'''", |
— | — | @@ -707,7 +707,7 @@ |
708 | 708 | 'centralauth-admin-already-unmerged' => 'Se brinca $1, ya deseparata.', |
709 | 709 | 'centralauth-admin-unmerge-success' => "S'{{PLURAL:$1|ha|han}} deseparato con esito $1 {{PLURAL:$1|cuenta|cuentas}}", |
710 | 710 | 'centralauth-admin-delete-title' => 'Borrar a cuenta', |
711 | | - 'centralauth-admin-delete-description' => "En borrar a cuenta global borrará todas as preferenzias globals, esligará todas as cuentas locals y deixará o nombre global libre ta que atro usuario pueda pillar-lo. |
| 711 | + 'centralauth-admin-delete-description' => "En borrar a cuenta global borrará todas as preferenzias globals, esligará todas as cuentas locals y deixará o nombre global libre ta que atro usuario pueda pillar-lo. |
712 | 712 | Todas as cuentas locals continarán esistindo. |
713 | 713 | As palabras de paso t'as cuentas locals creyatas antis d'a unificazión tornarán a estar as que yeran antis d'a mesma.", |
714 | 714 | 'centralauth-admin-delete-button' => 'Borrar esta cuenta', |
— | — | @@ -1853,7 +1853,7 @@ |
1854 | 1854 | Калі хто-небудзь заняў Вашае імя ўдзельніка на адным з праектаў, Ваш рахунак з чужым не аб'яднаецца, але Вы зможаце вырашыць гэтае пытаньне потым з удзельнікам альбо адміністратарам.", |
1855 | 1855 | 'centralauth-merge-step1-title' => "Пачатак аб'яднаньня рахункаў", |
1856 | 1856 | 'centralauth-merge-step1-detail' => 'Калі ласка, увядзіце тут пароль Вашага рахунка. |
1857 | | -Ваш пароль і адрас электроннай пошты будуць параўнаныя са зьвесткамі рахункаў у іншых вікі-праектах. |
| 1857 | +Ваш пароль і адрас электроннай пошты будуць параўнаныя са зьвесткамі рахункаў у іншых вікі-праектах. |
1858 | 1858 | Зьмены ня будуць праведзеныя, пакуль Вы не пацьвердзіце правільнасьць супастаўленьня.', |
1859 | 1859 | 'centralauth-merge-step1-submit' => 'Пацьвердзіць інфармацыю пра рахунак', |
1860 | 1860 | 'centralauth-merge-step2-title' => 'Пацьвердзіць дадатковыя рахункі', |
— | — | @@ -2063,7 +2063,7 @@ |
2064 | 2064 | Вы запыталі гэтую старонку бяз зьвестак аўтэнтыфікацыі, з-за гэтага нічога не адбываецца.', |
2065 | 2065 | 'globalgroupmembership' => 'Удзел у глябальных групах', |
2066 | 2066 | 'globalgrouppermissions' => 'Кіраваньне глябальнымі групамі', |
2067 | | - 'centralauth-globalgroupperms-grouplist' => 'Былі створаныя наступныя глябальныя групы. |
| 2067 | + 'centralauth-globalgroupperms-grouplist' => 'Былі створаныя наступныя глябальныя групы. |
2068 | 2068 | Вы можаце паглядзець і зьмяніць правы кожнай групы, калі маеце на гэта дазвол. |
2069 | 2069 | Група можа быць выдаленая праз выдаленьне зь яе ўсіх правоў.', |
2070 | 2070 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|прагляд/рэдагаваньне]])', |
— | — | @@ -2154,7 +2154,7 @@ |
2155 | 2155 | Ако някой друг вече е резервирал вашето потребителско име в друг проект, направената от вас единна сметка няма да му попречи да редактира, но ще ви даде възможност по-късно да преговаряте с потребителя да ви отстъпи тази сметка, или да поискате узурпирането ѝ от бюрократ.", |
2156 | 2156 | 'centralauth-merge-step1-title' => 'Започване на обединението на сметки', |
2157 | 2157 | 'centralauth-merge-step1-detail' => 'Необходимо е да въведете тук паролата за сметката си. |
2158 | | -Вашата парола и посоченият адрес за електронна поща ще бъдат сравнени със сметките в другите уикита, за да се потвърди съответствието между тях. |
| 2158 | +Вашата парола и посоченият адрес за електронна поща ще бъдат сравнени със сметките в другите уикита, за да се потвърди съответствието между тях. |
2159 | 2159 | Няма да се предприемат промени, докато не потвърдите, че всичко изглежда наред.', |
2160 | 2160 | 'centralauth-merge-step1-submit' => 'Потвърждаване на информацията за влизане', |
2161 | 2161 | 'centralauth-merge-step2-title' => 'Потвърждаване на още сметки', |
— | — | @@ -2639,7 +2639,7 @@ |
2640 | 2640 | 'centralauth-finish-password' => 'Ger-tremen :', |
2641 | 2641 | 'centralauth-finish-login' => 'Kont implijer :', |
2642 | 2642 | 'centralauth-finish-send-confirmation' => 'Kas ar ger-tremen dre bostel', |
2643 | | - 'centralauth-finish-problems' => "Ma c'hoarvez kudennoù pe ma noc'h ket perc'henn war ar c'hontoù-se, |
| 2643 | + 'centralauth-finish-problems' => "Ma c'hoarvez kudennoù pe ma noc'h ket perc'henn war ar c'hontoù-se, |
2644 | 2644 | sellit ouzh [[meta:Help:Unified login problems|Penaos bezañ skoazellet]]…", |
2645 | 2645 | 'centralauth-finish-noconfirms' => "N'eus bet gallet kadarnaat kont ebet gant ar ger-tremen-se.", |
2646 | 2646 | 'centralauth-finish-incomplete' => "Meur a gont zo bet kendeuzet en ur implijout ar ger-tremen-se. |
— | — | @@ -4277,7 +4277,7 @@ |
4278 | 4278 | Eka yewna merdim name tu guret, ma yin bêrexet niken, feqat ti eşkeno yin ra piya bihebit ya zi bace yew îdarekar ra.", |
4279 | 4279 | 'centralauth-merge-step1-title' => 'Yew kerdişê cikewtîşî başli bike', |
4280 | 4280 | 'centralauth-merge-step1-detail' => 'Ma rica keno paraloya hesabê xo îtiya de bike. |
4281 | | -Ma Paralo u adresê e-maîlê tu, ser hesabanê ke wîkîyan bînan de ser înan rê kontrol keno. |
| 4281 | +Ma Paralo u adresê e-maîlê tu, ser hesabanê ke wîkîyan bînan de ser înan rê kontrol keno. |
4282 | 4282 | Ma hesabê tu nivurneno heta tu konfirme bike ke her çî normal o.', |
4283 | 4283 | 'centralauth-merge-step1-submit' => 'Enformasyonê cikewtîşî konfirme bike', |
4284 | 4284 | 'centralauth-merge-step2-title' => 'Hesabanê binî konfirme bike', |
— | — | @@ -4287,7 +4287,7 @@ |
4288 | 4288 | 'centralauth-merge-dryrun-complete' => 'Hesabanê hemî eşkeno otomatik biyo yew! |
4289 | 4289 | |
4290 | 4290 | Hesabanê tu hama nivuriya.', |
4291 | | - 'centralauth-merge-dryrun-incomplete' => 'Nika ti eşkeno dewam bike, feqat tay hesaban ke ma nieşke otomatik konfirme bike, aye ra neqil kerdiş nibeno. |
| 4291 | + 'centralauth-merge-dryrun-incomplete' => 'Nika ti eşkeno dewam bike, feqat tay hesaban ke ma nieşke otomatik konfirme bike, aye ra neqil kerdiş nibeno. |
4292 | 4292 | Feqt ti eşkeno bace ena hesaban yew bike. |
4293 | 4293 | |
4294 | 4294 | Hesabanê tu hama nivuriya.', |
— | — | @@ -4313,7 +4313,7 @@ |
4314 | 4314 | Ma rica keno yew îdarakar rê yew mesaj bişirav ke ma unblok bike. |
4315 | 4315 | Nika ti nieşkeno hesabanê xo yew biker.', |
4316 | 4316 | 'centralauth-notice-dryrun' => "<div class='successbox'>Teyna mode demo</div><br clear='all'/>", |
4317 | | - 'centralauth-disabled-dryrun' => 'Hesabê yewinî hewna versiyonê demo / modê debugî de, yanî operasyonê yew kerdişî qefiniyayiyo. |
| 4317 | + 'centralauth-disabled-dryrun' => 'Hesabê yewinî hewna versiyonê demo / modê debugî de, yanî operasyonê yew kerdişî qefiniyayiyo. |
4318 | 4318 | Ma ef bike!', |
4319 | 4319 | 'centralauth-error-locked' => 'Ti nieşkeno bivurne çunkî hesabê tu kilit biyo.', |
4320 | 4320 | 'centralauth-readmore-text' => ":''[[meta:Help:Unified login|Ser '''cikewtîşê yewî''' biwane]]…''", |
— | — | @@ -4338,10 +4338,10 @@ |
4339 | 4339 | 'centralauth-finish-password' => 'Parola:', |
4340 | 4340 | 'centralauth-finish-login' => 'Cikewtîş', |
4341 | 4341 | 'centralauth-finish-send-confirmation' => 'Parala email ra bişirav', |
4342 | | - 'centralauth-finish-problems' => 'Sistem ti ra zor dano? Ya zi ti wahirê hesabanê binan niyo? |
| 4342 | + 'centralauth-finish-problems' => 'Sistem ti ra zor dano? Ya zi ti wahirê hesabanê binan niyo? |
4343 | 4343 | [[meta:Help:Unified login problems|Ti seni yardim vîneno]] ...', |
4344 | 4344 | 'centralauth-finish-noconfirms' => 'Ser ena paralo hesab çini yo.', |
4345 | | - 'centralauth-finish-incomplete' => 'Yew di hesab ser ena parola de yew biyo. |
| 4345 | + 'centralauth-finish-incomplete' => 'Yew di hesab ser ena parola de yew biyo. |
4346 | 4346 | Hesabanê binan hewna konfirme nibiyo.', |
4347 | 4347 | 'centralauth-merge-attempt' => "'''Ser hesabanê yew kerdişî, parola kontrol keno…'''", |
4348 | 4348 | 'centralauth-attach-list-attached' => 'Hesabê yew biyayîyê $1de enê hesaban estê:', |
— | — | @@ -4378,8 +4378,8 @@ |
4379 | 4379 | 'centralauth-admin-already-unmerged' => '$1 ra şino, zaten ciy biyo', |
4380 | 4380 | 'centralauth-admin-unmerge-success' => '$1 {{PLURAL:$1|hesab|hesaban}} ciya kerdo', |
4381 | 4381 | 'centralauth-admin-delete-title' => 'Hesab biwedarne', |
4382 | | - 'centralauth-admin-delete-description' => 'Esterayişê ena hesabê globalî tercihanê globalî, wedarneno, hesabanê lokalî qerifeno u eno nameyê globalî karberanê bînan ra a beno. |
4383 | | -Hesabanê lokalî niqefilneno. |
| 4382 | + 'centralauth-admin-delete-description' => 'Esterayişê ena hesabê globalî tercihanê globalî, wedarneno, hesabanê lokalî qerifeno u eno nameyê globalî karberanê bînan ra a beno. |
| 4383 | +Hesabanê lokalî niqefilneno. |
4384 | 4384 | Paralanê ke qe hesabanê lokalan reset beno u şino paralonê verinî.', |
4385 | 4385 | 'centralauth-admin-delete-button' => 'Ena hesab biwedarne', |
4386 | 4386 | 'centralauth-admin-delete-success' => 'Qe "<nowiki>$1</nowiki>" hesabê globalî wedarne', |
— | — | @@ -4449,12 +4449,12 @@ |
4450 | 4450 | 'centralauth-rightslog-set-optin' => 'ser opt-in', |
4451 | 4451 | 'centralauth-rightslog-set-optout' => 'ser opt-out', |
4452 | 4452 | 'autologin' => 'Cikewtîşê otomatîkî', |
4453 | | - 'centralauth-autologin-desc' => 'Ena pela xasî MediyaWîkî de sero kar beno. |
4454 | | -Çi wext ti [[Special:UserLogin|cikewtene]], sistemê cikewtiş ê merkezî browserê tu ra emir dano ke ena pele link biyo. |
| 4453 | + 'centralauth-autologin-desc' => 'Ena pela xasî MediyaWîkî de sero kar beno. |
| 4454 | +Çi wext ti [[Special:UserLogin|cikewtene]], sistemê cikewtiş ê merkezî browserê tu ra emir dano ke ena pele link biyo. |
4455 | 4455 | Ti ena pele waşto feqet datayê tu authentic niyo, aye ra nihebitiyeno.', |
4456 | 4456 | 'globalgroupmembership' => 'Grupanê globayan de eza biyayîş', |
4457 | 4457 | 'globalgrouppermissions' => 'Îdare kerdişê grupê globalî', |
4458 | | - 'centralauth-globalgroupperms-grouplist' => 'Enê grupanê globalî konfigure biyo. |
| 4458 | + 'centralauth-globalgroupperms-grouplist' => 'Enê grupanê globalî konfigure biyo. |
4459 | 4459 | Eka iznê tu esto, ti eşkeno desturanê yew grupî bivîn u bivurne. |
4460 | 4460 | Yew grup belki esteriyeno eka ti heqanê hemî biwedaro.', |
4461 | 4461 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|bivîne/bivurne]])', |
— | — | @@ -4481,7 +4481,7 @@ |
4482 | 4482 | 'centralauth-editgroup-perms' => 'Desturan bide:', |
4483 | 4483 | 'centralauth-editgroup-reason' => 'Sebeb:', |
4484 | 4484 | 'centralauth-editgroup-success' => 'Desturanê gruban vurîya', |
4485 | | - 'centralauth-editgroup-success-text' => 'Qe grupê $1î ti desturan da. |
| 4485 | + 'centralauth-editgroup-success-text' => 'Qe grupê $1î ti desturan da. |
4486 | 4486 | [[Special:GlobalGroupPermissions|Îdareyê grupî rê reyna şi]]', |
4487 | 4487 | 'centralauth-editgroup-editsets' => '([[Special:EditWikiSets|bivurne]])', |
4488 | 4488 | 'centralauth-globalgrouppermissions-knownwiki' => 'Wîkîyê ke hesabê tu esto:', |
— | — | @@ -4589,7 +4589,7 @@ |
4590 | 4590 | 'centralauth-merge-method-empty-desc' => 'Pódawa, až lokalne konto jo se zjadnośiło, dokulaž njejo měło změny.', |
4591 | 4591 | 'centralauth-merge-method-mail-desc' => 'Pódawa, až lokalne konto jo se zjadnośiła, dokulaž jogo e-mailowa adresa jo wótpowědowało e-mealowej adresy głownego konta.', |
4592 | 4592 | 'centralauth-merge-method-password-desc' => 'Pódawa, až lokalne konto jo se zjadnośiło, dokulaž wužywaŕ jo pódał płaśiwe gronidło za njo.', |
4593 | | - 'centralauth-merge-method-admin-desc' => 'Pódawa, až lokalne konto jo se manuelnje zjadnośiło wót stewardow. |
| 4593 | + 'centralauth-merge-method-admin-desc' => 'Pódawa, až lokalne konto jo se manuelnje zjadnośiło wót stewardow. |
4594 | 4594 | Toś ta funkcija jo něnto z pśicynow wěstoty znjemóžnjona.', |
4595 | 4595 | 'centralauth-merge-method-new-desc' => 'Pódawa, až globalne konto jo se awtomatiski napórało, gaž lokalne konto jo se napórało.', |
4596 | 4596 | 'centralauth-merge-method-login-desc' => 'Pódawa, až lokalne konto jo se awtomatiski napórało, gaž wužywaŕ jo se pśizjawił.', |
— | — | @@ -4844,7 +4844,7 @@ |
4845 | 4845 | Εάν κάποιος άλλος έχει ήδη πάρει το όνομα χρήστη σας σε άλλον ιστότοπο, αυτό δεν θα τον ενοχλήσει, θα σας δωθεί όμως την ευκαιρία αργότερα να λύσετε το πρόβλημα μαζί του ή με κάποιον διαχειριστή.", |
4846 | 4846 | 'centralauth-merge-step1-title' => 'Έναρξη ενοποίησης των λογαριασμών', |
4847 | 4847 | 'centralauth-merge-step1-detail' => 'Παρακαλώ εισάγεται τον κωδικό του λογαριασμού σας. |
4848 | | -Ο κωδικός σας και η ηλεκτρονική διεύθυνση που έχετε δηλώσει θα υποβληθούν σε έλεγχο με τους λογαριασμούς σε άλλα εγχειρήματα για να επιβεβαιωθεί ότι ταιριάζουν. |
| 4848 | +Ο κωδικός σας και η ηλεκτρονική διεύθυνση που έχετε δηλώσει θα υποβληθούν σε έλεγχο με τους λογαριασμούς σε άλλα εγχειρήματα για να επιβεβαιωθεί ότι ταιριάζουν. |
4849 | 4849 | Δεν θα γίνει καμία αλλαγή έως ότου επιβεβαιώσετε ότι τα πάντα είναι εντάξει.', |
4850 | 4850 | 'centralauth-merge-step1-submit' => 'Επαλήθευση των πληροφοριών σύνδεσης', |
4851 | 4851 | 'centralauth-merge-step2-title' => 'Επιβεβαίωση περισσότερων λογαριασμών', |
— | — | @@ -5101,27 +5101,27 @@ |
5102 | 5102 | 'centralauth-merge-notlogged' => 'Bonvolu <span class="plainlinks">[{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} ensaluti]</span> por kontroli ĉu viaj kontoj ja plene kunfandiĝis.', |
5103 | 5103 | 'centralauth-merge-welcome' => "'''Via uzanto-konto ne jam estis migrigita al unuigita salutsistemo de {{MediaWiki:Centralauth-groupname}}.''' |
5104 | 5104 | |
5105 | | -Se vi elektas migrigi viajn kontojn, vi povos uzi la saman uzulnomon kaj pasvorton por ensaluti en cxiuj vikioj de la projektoj de {{MediaWiki:Centralauth-groupname}} en ĉiuj haveblaj lingvoj. |
| 5105 | +Se vi elektas migrigi viajn kontojn, vi povos uzi la saman uzulnomon kaj pasvorton por ensaluti en cxiuj vikioj de la projektoj de {{MediaWiki:Centralauth-groupname}} en ĉiuj haveblaj lingvoj. |
5106 | 5106 | |
5107 | 5107 | Se iu alia jam prenis vian uzanto-nomon sur alia paĝaro, tio donos al vi ŝancon ekrilati kun tiu aŭ kun administranto pli poste.", |
5108 | 5108 | 'centralauth-merge-step1-title' => 'Komenci salutnoman unuigadon.', |
5109 | 5109 | 'centralauth-merge-step1-detail' => 'Bonvolu enigi ĉi tie la pasvorton de via konto. |
5110 | | -Via pasvorto kaj registrita retadreso estos kontrolitaj kompare kun la kontoj sur aliaj vikioj por konfirmi ke ili kongruas. |
| 5110 | +Via pasvorto kaj registrita retadreso estos kontrolitaj kompare kun la kontoj sur aliaj vikioj por konfirmi ke ili kongruas. |
5111 | 5111 | Neniu ŝanĝo estos farita ĝis vi konfirmos ke ĉio aspektas en ordo.', |
5112 | 5112 | 'centralauth-merge-step1-submit' => 'Konfirmi salutadan informon', |
5113 | 5113 | 'centralauth-merge-step2-title' => 'Konfirmi pluajn kontojn', |
5114 | | - 'centralauth-merge-step2-detail' => 'Iuj el la kontoj ne povis esti aŭtomate ligitaj al la menciita hejma vikio. |
| 5114 | + 'centralauth-merge-step2-detail' => 'Iuj el la kontoj ne povis esti aŭtomate ligitaj al la menciita hejma vikio. |
5115 | 5115 | Se ĉi tiuj kontoj apartenas al vi, vi povas konfirmi, ke ili estas viaj provizante la pasvorton por ili.', |
5116 | 5116 | 'centralauth-merge-step2-submit' => 'Konfirmi salutinformon', |
5117 | 5117 | 'centralauth-merge-dryrun-complete' => 'Ĉiuj ekzistantaj kontoj povas esti aŭtomate unuigita! |
5118 | 5118 | |
5119 | 5119 | Neniu sxanĝo estis jam farita al viaj kontoj.', |
5120 | | - 'centralauth-merge-dryrun-incomplete' => 'Vi decidis daŭrigi sed iuj kontoj ne povis esti aŭtomate kontrolitaj kaj ne estos migrigitaj tuje. |
5121 | | -Vi povos tion fari pli poste. |
| 5120 | + 'centralauth-merge-dryrun-incomplete' => 'Vi decidis daŭrigi sed iuj kontoj ne povis esti aŭtomate kontrolitaj kaj ne estos migrigitaj tuje. |
| 5121 | +Vi povos tion fari pli poste. |
5122 | 5122 | |
5123 | 5123 | Neniu sxanĝo estis jam farita al viaj kontoj.', |
5124 | 5124 | 'centralauth-merge-dryrun-or' => "'''aŭ'''", |
5125 | | - 'centralauth-merge-dryrun-home' => 'La migrada sistemo ne povis konfirmi ke vi estas la posedanto de la konto en la hejma vikio por via saltunomo. |
| 5125 | + 'centralauth-merge-dryrun-home' => 'La migrada sistemo ne povis konfirmi ke vi estas la posedanto de la konto en la hejma vikio por via saltunomo. |
5126 | 5126 | |
5127 | 5127 | Alia vikio estis difinita kiel hejma konto por via salutnomo; sekvu la ligilon suban kaj ensalutu tie por finfari la migrigon de via konto.', |
5128 | 5128 | 'centralauth-merge-step3-title' => 'Krei unuigitan konton', |
— | — | @@ -5314,8 +5314,8 @@ |
5315 | 5315 | Vi petis ĉi tiun paĝon sen donante ian ajn aŭtentoinformon, do ĝi faras nenion.', |
5316 | 5316 | 'globalgroupmembership' => 'Membreco en ĝeneralaj grupoj', |
5317 | 5317 | 'globalgrouppermissions' => 'Ĝenerala administrado de grupoj', |
5318 | | - 'centralauth-globalgroupperms-grouplist' => 'La jenaj ĝeneralaj grupoj estis konfiguritaj. |
5319 | | -Vi povas vidi aŭ redakti la rajtojn asignitajn al ĉiu grupo, se vi havas tian ĝustan rajton. |
| 5318 | + 'centralauth-globalgroupperms-grouplist' => 'La jenaj ĝeneralaj grupoj estis konfiguritaj. |
| 5319 | +Vi povas vidi aŭ redakti la rajtojn asignitajn al ĉiu grupo, se vi havas tian ĝustan rajton. |
5320 | 5320 | Vi povas forigi grupon per forigo de ĉiuj ĝiaj rajtoj.', |
5321 | 5321 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|vidi/redakti]])', |
5322 | 5322 | 'centralauth-globalgroupperms-nogroups' => 'Neniuj ĝeneralaj grupoj estas difinitaj.', |
— | — | @@ -5346,7 +5346,7 @@ |
5347 | 5347 | 'centralauth-editset' => 'Vikiaroj', |
5348 | 5348 | 'centralauth-editset-legend-rw' => 'Redakti aŭ krei vikiaron', |
5349 | 5349 | 'centralauth-editset-legend-ro' => 'Listo de vikiaroj', |
5350 | | - 'centralauth-editset-intro-rw' => 'La jenaj vikiaroj estis jam kreitaj. |
| 5350 | + 'centralauth-editset-intro-rw' => 'La jenaj vikiaroj estis jam kreitaj. |
5351 | 5351 | Vi povas vidi kaj modifi iujn el ili, aŭ krei novan vikiaron.', |
5352 | 5352 | 'centralauth-editset-intro-ro' => 'Jen listo de ekzistantaj vikiaroj.', |
5353 | 5353 | 'centralauth-editset-item-rw' => '[[Special:WikiSets/$2|$1]] ([[Special:WikiSets/delete/$2|forigi]])', |
— | — | @@ -7997,7 +7997,7 @@ |
7998 | 7998 | अगर किसी औरने आपका सदस्यनाम पहले से ले लिया हैं तो आप उनसे संपर्क करके अथवा प्रबंधकोंके द्वारा बदलाव किये जा सकतें हैं।", |
7999 | 7999 | 'centralauth-merge-step1-title' => 'खाता एकत्रिकरण शुरू करें', |
8000 | 8000 | 'centralauth-merge-step1-detail' => 'कृपया आपका कूटशब्द यहाँ लिखें। |
8001 | | -आपका कूटशब्द और इ-मेल एड्रेस अन्य विकियों के साथ जाँचा जायेगा। |
| 8001 | +आपका कूटशब्द और इ-मेल एड्रेस अन्य विकियों के साथ जाँचा जायेगा। |
8002 | 8002 | जब तक आप अनुमति नहीं देते तब तक कोई भी बदलाव नहीं किये जायेंगे।', |
8003 | 8003 | 'centralauth-merge-step1-submit' => 'खाता ज़ानकारी को सहमती दें', |
8004 | 8004 | 'centralauth-merge-step2-title' => 'अन्य खाता निश्चित करें', |
— | — | @@ -8058,7 +8058,7 @@ |
8059 | 8059 | 'centralauth-merge-attempt' => "'''आपका दिया हुआ कूटशब्द अन्य समावेश न हुए अकाउंट के लिये परखा जा रहा हैं...'''", |
8060 | 8060 | 'centralauth-attach-list-attached' => '"$1" इस एकत्रित अकाउंटमें निम्नलिखित अकाउंट हैं:', |
8061 | 8061 | 'centralauth-attach-title' => 'खाता निश्चिती करें', |
8062 | | - 'centralauth-attach-text' => 'यह अकाउंट एकत्रित अकाउंटमें नहीं हैं। |
| 8062 | + 'centralauth-attach-text' => 'यह अकाउंट एकत्रित अकाउंटमें नहीं हैं। |
8063 | 8063 | अगर एकत्रित अकाउंट आपकाही हैं, तो उसका कूटशब्द देकर आप इसे जोड सकतें हैं:', |
8064 | 8064 | 'centralauth-attach-submit' => 'खाता स्थलांतरित करें', |
8065 | 8065 | 'centralauth-attach-success' => 'खाता एकत्रित खातेसे जोड दिया गया हैं।', |
— | — | @@ -8196,7 +8196,7 @@ |
8197 | 8197 | Ukoliko je netko već uporabio vaše ime/nadimak na nekom drugom projektu, ovo neće smetati niti jednu stranu, nego će vam dati šansu da se konflikt naknadno riješi s njima ili administratorom.", |
8198 | 8198 | 'centralauth-merge-step1-title' => 'Počni spajanje suradničkih računa', |
8199 | 8199 | 'centralauth-merge-step1-detail' => 'Ovdje unesite lozinku za svoj suradnički račun. |
8200 | | -Vaša lozinka i prijavljena e-mail adresa će biti uspoređeni s podacima na drugim wikijima da se ustanovi da li odgovaraju jedni drugima. |
| 8200 | +Vaša lozinka i prijavljena e-mail adresa će biti uspoređeni s podacima na drugim wikijima da se ustanovi da li odgovaraju jedni drugima. |
8201 | 8201 | Promjene neće biti izvršene dok ne potvrdite da je sve u redu.', |
8202 | 8202 | 'centralauth-merge-step1-submit' => 'Potvrdi podatke o prijavi', |
8203 | 8203 | 'centralauth-merge-step2-title' => 'Potvrdi više suradničkih računa', |
— | — | @@ -8427,7 +8427,7 @@ |
8428 | 8428 | 'centralauth-merge-notlogged' => 'Prošu <span class="plainlinks"> [{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} přizjew so]</span>, zo by přepruwował, hač su so twoje wužiwarske konta dospołnje zjednoćili.', |
8429 | 8429 | 'centralauth-merge-welcome' => "'''Twoje wužiwarske konto njeje so hišće do zhromadneho systema přizjewjenja {{MediaWiki:Centralauth-groupname}} přeměstniło.''' |
8430 | 8430 | |
8431 | | -Hdyž so rozsudźiš twoje konta přeměstnić, budźe móžno smasne wužiwarske mjeno a hesło we wšěch |
| 8431 | +Hdyž so rozsudźiš twoje konta přeměstnić, budźe móžno smasne wužiwarske mjeno a hesło we wšěch |
8432 | 8432 | wikijach {{MediaWiki:Centralauth-groupname}} we wšěch k dispoziciji stejacych rěčach wužiwać. |
8433 | 8433 | |
8434 | 8434 | Jeli něchtó druhi twoje wužiwarske mjeno na druhim sydle wužiwa, njebudźe to mylić. ale da ći móžnosć z tym wužiwarjom abo administratorom tón problem pozdźišo rozrisać.", |
— | — | @@ -10227,9 +10227,9 @@ |
10228 | 10228 | 'centralauth-desc' => '[[Special:MergeAccount|Merge bruger]] en Wikimedia Fundåsje wikier', |
10229 | 10229 | 'centralauth-mergeaccount-desc' => '[[Special:MergeAccount|Merge multiiple bruger]] før Lænsøm Bruger Loĝ På', |
10230 | 10230 | 'centralauth-merge-denied' => 'Unskyld, du harst ekke permisje til aksesær dette pæge.', |
10231 | | - 'centralauth-merge-welcome' => "'''Your bruger beretning har ikke endnu blevet migræne hen til Wikimedia's samlet login system.''' |
| 10231 | + 'centralauth-merge-welcome' => "'''Your bruger beretning har ikke endnu blevet migræne hen til Wikimedia's samlet login system.''' |
10232 | 10232 | |
10233 | | -Selv om jer gide hen til migræne jeres regnskab , du vil være i stand til hjælp den samme username og password hen til log i hen til al i Wikimedia's planlægge wikis i alt anvendelig sprogene. Indeværende gør sig lettere hen til operere med delt anlægsarbejder såsom sender hen til [http://commons.wikimedia.org/ Wikimedia Commons], og forhindrer den sammenblanding eller konflikt at kunne opstå af to folk piller den samme username oven på anderledes anlægsarbejder. |
| 10233 | +Selv om jer gide hen til migræne jeres regnskab , du vil være i stand til hjælp den samme username og password hen til log i hen til al i Wikimedia's planlægge wikis i alt anvendelig sprogene. Indeværende gør sig lettere hen til operere med delt anlægsarbejder såsom sender hen til [http://commons.wikimedia.org/ Wikimedia Commons], og forhindrer den sammenblanding eller konflikt at kunne opstå af to folk piller den samme username oven på anderledes anlægsarbejder. |
10234 | 10234 | |
10235 | 10235 | Selv om nogen ellers har allerede taget jeres username oven på en anden arbejdsplads indeværende vil ikke forstyrre sig , men sig vil indrømme jer en hændelse hen til beregne hos sig eller en administrator senere.", |
10236 | 10236 | 'centralauth-merge-step1-title' => 'Bigynde login unifikåsje', |
— | — | @@ -10245,7 +10245,7 @@ |
10246 | 10246 | 'centralauth-incomplete' => 'Login unifikåsje udun!', |
10247 | 10247 | 'centralauth-complete-text' => 'Jer kunne nu log i hen til hvilken som helst Wikimedia wiki arbejdsplads uden skaber en ny beretning ; den samme username og password vil arbejde med Wikipedia Wiktionary Wikibooks , og deres afdelingssygeplejersken anlægsarbejder i alt sprogene.', |
10248 | 10248 | 'centralauth-incomplete-text' => 'Når først jeres login er samlet , jer vil være i stand til log i hen til hvilken som helst Wikimedia wiki arbejdsplads uden skaber en ny beretning ; den samme username og password vil arbejde med Wikipedia Wiktionary Wikibooks , og deres afdelingssygeplejersken anlægsarbejder i alt sprogene.', |
10249 | | - 'centralauth-not-owner-text' => 'Den username "$1" var automatisk bestemt hen til den indehaver i den beretning oven på $2. |
| 10249 | + 'centralauth-not-owner-text' => 'Den username "$1" var automatisk bestemt hen til den indehaver i den beretning oven på $2. |
10250 | 10250 | |
10251 | 10251 | Selv om indeværende er jer , jer kunne komme ind den login unification oparbejde simpelt hen ved at taste den lærer password nemlig at beretning her ovre :', |
10252 | 10252 | 'centralauth-notice-dryrun' => "<div class='successbox'>Demo mode ålen</div><br clear='all'/>", |
— | — | @@ -10285,7 +10285,7 @@ |
10286 | 10286 | Yèn wong liya wis njupuk jeneng panganggo panjenengan ing situs liya, perkara iki ora bakal ngrusuhi wong iku, nanging mengkoné perkara iki bisa mènèhi panjenengan kasempatan kanggo golèk solusi ing masalah iki karo wong iku utawa sang pangurus/kuncèné ing proyèk iku.", |
10287 | 10287 | 'centralauth-merge-step1-title' => 'Miwitana unifikasi log mlebu', |
10288 | 10288 | 'centralauth-merge-step1-detail' => 'Mangga isi tembung sandi akun panjenengan. |
10289 | | -Tembung sandi lan alamat e-mail panjenengan bakal dibandhingaké karo akun ing wiki-wiki liyané kanggo ndhedhes kacocogané. |
| 10289 | +Tembung sandi lan alamat e-mail panjenengan bakal dibandhingaké karo akun ing wiki-wiki liyané kanggo ndhedhes kacocogané. |
10290 | 10290 | Owah-owahan ora bisa dilakoni nganti panjenengan ndhedhes yèn ora ana masalah.', |
10291 | 10291 | 'centralauth-merge-step1-submit' => 'Dhedhesen (konfirmasi) log mlebu', |
10292 | 10292 | 'centralauth-merge-step2-title' => 'Konfirmasi rékening (akun) liya', |
— | — | @@ -10436,8 +10436,8 @@ |
10437 | 10437 | Panjenengan wis ngaksès kaca iki tanpa mènèhi data otentikasi, saéngga kaca iki ora mènèhi réaksi apa-apa.', |
10438 | 10438 | 'globalgroupmembership' => 'Kaanggotan ing kelompok-kelompok global', |
10439 | 10439 | 'globalgrouppermissions' => 'Ngurus kelompok global', |
10440 | | - 'centralauth-globalgroupperms-grouplist' => 'Klompok global sing kapacak ing ngisor iki wis dikonfigurasi. |
10441 | | -Panjenengan bisa ndeleng utawa nyunting hak sing diwènèhaké ing saben klompok, yèn panjenengan nduwèni hak kanggo kuwi. |
| 10440 | + 'centralauth-globalgroupperms-grouplist' => 'Klompok global sing kapacak ing ngisor iki wis dikonfigurasi. |
| 10441 | +Panjenengan bisa ndeleng utawa nyunting hak sing diwènèhaké ing saben klompok, yèn panjenengan nduwèni hak kanggo kuwi. |
10442 | 10442 | Sawijining klompok bisa dibusak kanthi ngilangi kabèh hak saka klompok iku.', |
10443 | 10443 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|deleng/sunting]])', |
10444 | 10444 | 'centralauth-existinggroup-legend' => 'Kelompok-kelompok sing wis ana', |
— | — | @@ -10558,7 +10558,7 @@ |
10559 | 10559 | 'centralauth-admin-already-unmerged' => ' გატარება $1 უკვე დაყოფილია', |
10560 | 10560 | 'centralauth-admin-unmerge-success' => 'წარმატებით დაიყო $1 {{PLURAL:$1|ანგარიში|ანგარიშები|ანგარიშების}}', |
10561 | 10561 | 'centralauth-admin-delete-title' => 'ანგარიშის წაშლა', |
10562 | | - 'centralauth-admin-delete-description' => 'გლობალური ანგარიშის წაშლა გამოიწვევს გლობალური კონფიგურაციის წაშლას, ყველა ანგარიშის გაყოფას და გლობალური ანგარიშის სახელის განთავისუფლება, რაც მისცემს სხვა მომხმარებელს დაიკავოს ეს სახელი. |
| 10562 | + 'centralauth-admin-delete-description' => 'გლობალური ანგარიშის წაშლა გამოიწვევს გლობალური კონფიგურაციის წაშლას, ყველა ანგარიშის გაყოფას და გლობალური ანგარიშის სახელის განთავისუფლება, რაც მისცემს სხვა მომხმარებელს დაიკავოს ეს სახელი. |
10563 | 10563 | ყველა ლოკალური ანგარიში გააგრძელებს არსებობას. |
10564 | 10564 | იმ ლოკალური ანგარიშების პაროლები, როლებიც გაერთიანებამდე შეიქმნა, დაიბრუნებენ პირვანდელ კომბინაციებს. |
10565 | 10565 | Все локальные учётные записи продолжат существовать. |
— | — | @@ -11719,7 +11719,7 @@ |
11720 | 11720 | 'centralauth-attach-list-attached' => 'Di jemeinsame Aanmeldung met däm Metmaacher-Name „$1“ ömfaß:', |
11721 | 11721 | 'centralauth-attach-title' => 'Aanmeldung bestätije', |
11722 | 11722 | 'centralauth-attach-text' => 'Di Aanmeldung als ene Metmaacher wood noch nit an en |
11723 | | -jemeinsame Aanmeldung aanjehange. |
| 11723 | +jemeinsame Aanmeldung aanjehange. |
11724 | 11724 | Wann et esu es, dat och de jemeinsame Aanmeldung |
11725 | 11725 | met dämm Name de Dinge es, dann kanns De och hee di |
11726 | 11726 | Aanmeldung bei di Jemeinsame dobei donn, indämm dat |
— | — | @@ -12240,7 +12240,7 @@ |
12241 | 12241 | 'centralauth-merge-notlogged' => '<span class="plainlinks">[{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} Meld dich aan]</span> óm te controlere of dien gebroekersaccounts al-oet zeen samegevoog.', |
12242 | 12242 | 'centralauth-merge-welcome' => "'''Dien gebroekersaccount is nog neet gemigreerd nao 't samegevoog aanmeldsysteem van {{MediaWiki:Centralauth-groupname}}.''' |
12243 | 12243 | |
12244 | | -Es te d'rveur keus óm dien gebroekersaccounts te migrere, den kèns te dich mit dezelfde gebroekersnaam-wachwaordcombinatie aanmelje bie alle projekte van {{MediaWiki:Centralauth-groupname}} in alle besjikbaar täöl. |
| 12244 | +Es te d'rveur keus óm dien gebroekersaccounts te migrere, den kèns te dich mit dezelfde gebroekersnaam-wachwaordcombinatie aanmelje bie alle projekte van {{MediaWiki:Centralauth-groupname}} in alle besjikbaar täöl. |
12245 | 12245 | |
12246 | 12246 | Es emes angers mit diene gebroekersnaam al actief is op 'ne angere site, den haet det gein gevolge veur dae gebroeker. De höbs de mäögelikheid det mit dae gebroeker of 'ne beheerder op 'n later memènt op te losse.", |
12247 | 12247 | 'centralauth-merge-step1-title' => 'Begin gebroekerssamevoege', |
— | — | @@ -13196,7 +13196,7 @@ |
13197 | 13197 | കാര്യങ്ങൾ എല്ലാം ശരിയാണെന്നു താങ്കൾ ഉറപ്പിക്കുന്നതു വരെ ഒരു മാറ്റവും വരുത്തുന്നതല്ല.', |
13198 | 13198 | 'centralauth-merge-step1-submit' => 'ലോഗിൻ വിവരം സ്ഥിരീകരിക്കുക', |
13199 | 13199 | 'centralauth-merge-step2-title' => 'കൂടുതൽ അംഗത്വങ്ങൾ സ്ഥിരീകരിക്കുക', |
13200 | | - 'centralauth-merge-step2-detail' => 'ചില അംഗത്വങ്ങൾക്ക് തറവാട് വിക്കിയിലെ അംഗത്വവുമായി യാന്ത്രികമായി ചേർച്ചയില്ല എന്നു കാണുന്നു. |
| 13200 | + 'centralauth-merge-step2-detail' => 'ചില അംഗത്വങ്ങൾക്ക് തറവാട് വിക്കിയിലെ അംഗത്വവുമായി യാന്ത്രികമായി ചേർച്ചയില്ല എന്നു കാണുന്നു. |
13201 | 13201 | ഈ അംഗത്വങ്ങൾ താങ്കളുടെ തന്നെയാണെന്നുറപ്പുണ്ടെങ്കിൽ ശരിയായ രഹസ്യവാക്ക് കൊടുത്ത് താങ്കൾക്ക് ഈ അംഗത്വങ്ങളെ താങ്കൾക്ക് സ്ഥിരീകരിക്കാവുന്നതാണ്.', |
13202 | 13202 | 'centralauth-merge-step2-submit' => 'ലോഗിൻ വിവരം സ്ഥിരീകരിക്കുക', |
13203 | 13203 | 'centralauth-merge-dryrun-complete' => 'നിലവിലുള്ള എല്ലാ അംഗത്വങ്ങളും യാന്ത്രികമായി സംയോജിപ്പിക്കാവുന്നതാണ്.', |
— | — | @@ -13258,10 +13258,10 @@ |
13259 | 13259 | 'centralauth-finish-password' => 'രഹസ്യവാക്ക്:', |
13260 | 13260 | 'centralauth-finish-login' => 'ലോഗിൻ', |
13261 | 13261 | 'centralauth-finish-send-confirmation' => 'രഹസ്യവാക്ക് ഇമെയിൽ ചെയ്യുക', |
13262 | | - 'centralauth-finish-problems' => 'താങ്കൾ എന്തെങ്കിലും ബുദ്ധിമുട്ടു അനുഭവിക്കുന്നോ, അല്ലെങ്കിൽ ഇവിടെ പ്രദർശിപ്പിച്ചിരിക്കുന്ന മറ്റു അംഗത്വങ്ങൾ താങ്കളുടെ അല്ലേ? |
| 13262 | + 'centralauth-finish-problems' => 'താങ്കൾ എന്തെങ്കിലും ബുദ്ധിമുട്ടു അനുഭവിക്കുന്നോ, അല്ലെങ്കിൽ ഇവിടെ പ്രദർശിപ്പിച്ചിരിക്കുന്ന മറ്റു അംഗത്വങ്ങൾ താങ്കളുടെ അല്ലേ? |
13263 | 13263 | [[meta:Help:Unified login problems|സഹായത്തിനു സന്ദർശിക്കുക]]…', |
13264 | 13264 | 'centralauth-finish-noconfirms' => 'ഈ രഹസ്യവാക്ക് ഉപയോഗിച്ച് ഒരു അംഗത്വവും സ്ഥിരീകരിക്കുവാൻ പറ്റിയില്ല.', |
13265 | | - 'centralauth-finish-incomplete' => 'ഈ രഹസ്യവാക്കുപയോഗിച്ച് നിരവധി അംഗത്വങ്ങൾ സംയോജിപ്പിട്ടുണ്ട്. |
| 13265 | + 'centralauth-finish-incomplete' => 'ഈ രഹസ്യവാക്കുപയോഗിച്ച് നിരവധി അംഗത്വങ്ങൾ സംയോജിപ്പിട്ടുണ്ട്. |
13266 | 13266 | മറ്റു അംഗത്വങ്ങൾ ഇതു വരെ സ്ഥിരീകരിച്ചിട്ടില്ല.', |
13267 | 13267 | 'centralauth-merge-attempt' => "'''തന്നിരിക്കുന്ന രഹസ്യവാക്കു ബാക്കിയുള്ള സംയോജിപ്പിക്കാത്ത അംഗത്വങ്ങളുമായി പരിശോധിക്കുന്നു…'''", |
13268 | 13268 | 'centralauth-attach-list-attached' => '"$1" എന്ന സംയോജിത അംഗത്വത്തിൽ താഴെ പ്രദർശിപ്പിച്ചിരിക്കുന്ന അംഗത്വങ്ങളും ഉൾപ്പെടുന്നു:', |
— | — | @@ -13308,7 +13308,7 @@ |
13309 | 13309 | 'centralauth-admin-already-unmerged' => 'ഇതിനകം വിഘടിപ്പിച്ചതിനാൽ $1നെ വിട്ടുകളയുന്നു', |
13310 | 13310 | 'centralauth-admin-unmerge-success' => '$1 {{PLURAL:$1|അംഗത്വം|അംഗത്വങ്ങൾ}} വിജയകരമായി വിഘടിപ്പിച്ചിരിക്കുന്നു.', |
13311 | 13311 | 'centralauth-admin-delete-title' => 'അംഗത്വം മായ്ക്കുക', |
13312 | | - 'centralauth-admin-delete-description' => 'ആഗോള അംഗത്വം മായ്ക്കുന്നത് ആഗോള ക്രമീകരണങ്ങൾ മായ്ക്കുകയും, ആഗോള അംഗത്വത്തിനോടൊപ്പം ചേർത്തിരിക്കുന്ന പ്രാദേശിക അംഗത്വങ്ങളെ സ്വതന്ത്രമാക്കുകയും, ആഗോള അംഗത്വത്തിന്റെ ഉപയോക്തൃനാമം മറ്റൊരു ഉപയോക്താവിനു തിരഞ്ഞെടുക്കാൻ പ്രാപ്തമാക്കുകയും ചെയ്യും. |
| 13312 | + 'centralauth-admin-delete-description' => 'ആഗോള അംഗത്വം മായ്ക്കുന്നത് ആഗോള ക്രമീകരണങ്ങൾ മായ്ക്കുകയും, ആഗോള അംഗത്വത്തിനോടൊപ്പം ചേർത്തിരിക്കുന്ന പ്രാദേശിക അംഗത്വങ്ങളെ സ്വതന്ത്രമാക്കുകയും, ആഗോള അംഗത്വത്തിന്റെ ഉപയോക്തൃനാമം മറ്റൊരു ഉപയോക്താവിനു തിരഞ്ഞെടുക്കാൻ പ്രാപ്തമാക്കുകയും ചെയ്യും. |
13313 | 13313 | |
13314 | 13314 | പ്രാദേശിക അംഗത്വങ്ങൾ അതത് വിക്കികളിൽ നിലനിൽക്കും. പ്രാദേശിക അംഗത്വങ്ങളുടെ രഹസ്യവാക്ക് സംയോജനത്തിനു മുൻപുണ്ടായിരുന്ന രഹസ്യവാക്ക് ആയിരിക്കും.', |
13315 | 13315 | 'centralauth-admin-delete-button' => 'ഈ അംഗത്വം മായ്ക്കുക', |
— | — | @@ -13402,7 +13402,7 @@ |
13403 | 13403 | എന്തെങ്കിലും തിരിച്ചറിയാനുള്ള വിവരങ്ങൾ ഇല്ലാതെയാണ് താങ്കൾ ഈ താൾ ആവശ്യപ്പെട്ടിരിക്കുന്നത്, അതുകൊണ്ടിത് ഒന്നും ചെയ്യുന്നില്ല.', |
13404 | 13404 | 'globalgroupmembership' => 'ആഗോള സംഘങ്ങളിലുള്ള അംഗത്വം', |
13405 | 13405 | 'globalgrouppermissions' => 'ആഗോള സംഘ നിർവഹണം', |
13406 | | - 'centralauth-globalgroupperms-grouplist' => 'താഴെ പ്രദർശിപ്പിച്ചിരിക്കുന്ന ആഗോള സംഘങ്ങൾ സജ്ജീകരിച്ചിരിക്കുന്നു. |
| 13406 | + 'centralauth-globalgroupperms-grouplist' => 'താഴെ പ്രദർശിപ്പിച്ചിരിക്കുന്ന ആഗോള സംഘങ്ങൾ സജ്ജീകരിച്ചിരിക്കുന്നു. |
13407 | 13407 | താങ്കൾക്ക് അനുമതിയുണ്ടെങ്കിൽ, ഏതെങ്കിലും ഒരു സംഘത്തിനു കൊടുത്തിരിക്കുന്ന അവകാശങ്ങൾ താങ്കൾക്കു കാണുകയും തിരുത്തുകയും ചെയ്യാവുന്നതാണ്. |
13408 | 13408 | എല്ലാ അവകാശങ്ങളും മാറ്റിയതിനു ശേഷം ഏതെങ്കിലും ഒരു സംഘത്തിനെ മായ്ച്ചു കളയാവുന്നതും ആണ്.', |
13409 | 13409 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|കാണുക/തിരുത്തുക]])', |
— | — | @@ -14710,8 +14710,8 @@ |
14711 | 14711 | 'centralauth-admin-already-unmerged' => 'Hoppar over $1, skilt ut frå før', |
14712 | 14712 | 'centralauth-admin-unmerge-success' => 'Skilde ut {{PLURAL:$1|éin konto|$1 kontoar}}', |
14713 | 14713 | 'centralauth-admin-delete-title' => 'Slett brukarkonto', |
14714 | | - 'centralauth-admin-delete-description' => 'Sletting av den globale kontoen vil sletta globale innstillingar, skilja ut alle lokale kontoar og gjera det globale namnet tilgjengeleg for andre brukarar. |
14715 | | -Alle lokale kontoar vil halda fram med å eksistera. |
| 14714 | + 'centralauth-admin-delete-description' => 'Sletting av den globale kontoen vil sletta globale innstillingar, skilja ut alle lokale kontoar og gjera det globale namnet tilgjengeleg for andre brukarar. |
| 14715 | +Alle lokale kontoar vil halda fram med å eksistera. |
14716 | 14716 | Passorda til lokale kontoar oppretta før samanslåinga vil gå attende til verdiane dei hadde før samanslåinga.', |
14717 | 14717 | 'centralauth-admin-delete-button' => 'Slette denne kontoen', |
14718 | 14718 | 'centralauth-admin-delete-success' => 'Sletta den globale kontoen for «<nowiki>$1</nowiki>»', |
— | — | @@ -14745,7 +14745,7 @@ |
14746 | 14746 | 'centralauth-prefs-count-unattached' => 'Ikkje-stadfesta kontoar med namnet ditt står att på {{PLURAL:$1|éitt prosjekt|$1 prosjekt}}.', |
14747 | 14747 | 'centralauth-prefs-detail-unattached' => 'Det er ikkje stadfesta at denne kontoen er slått saman med hovudkontoen.', |
14748 | 14748 | 'centralauth-prefs-manage' => 'Handsam hovudkontoen din', |
14749 | | - 'centralauth-renameuser-merged' => 'Brukaren $1 har gått over til det globale kontosystemet. |
| 14749 | + 'centralauth-renameuser-merged' => 'Brukaren $1 har gått over til det globale kontosystemet. |
14750 | 14750 | Å endra namnet på kontoen vil føra til at den lokale brukaren blir skilt frå den globale kontoen.', |
14751 | 14751 | 'centralauth-renameuser-reserved' => 'Brukarnamnet $2 er reservert for ein global konto.', |
14752 | 14752 | 'centralauth-invalid-wiki' => 'Wikidatabasen finst ikkje: $1', |
— | — | @@ -14810,7 +14810,7 @@ |
14811 | 14811 | 'centralauth-editgroup-perms' => 'Tildelte løyve:', |
14812 | 14812 | 'centralauth-editgroup-reason' => 'Endringsårsak:', |
14813 | 14813 | 'centralauth-editgroup-success' => 'Gruppeløyve endra', |
14814 | | - 'centralauth-editgroup-success-text' => 'Du har endra gruppeløyva til gruppa $1. |
| 14814 | + 'centralauth-editgroup-success-text' => 'Du har endra gruppeløyva til gruppa $1. |
14815 | 14815 | [[Special:GlobalGroupPermissions|Attende til gruppehandsaming]]', |
14816 | 14816 | 'centralauth-editgroup-editsets' => '([[Special:EditWikiSets|endra]])', |
14817 | 14817 | 'centralauth-globalgrouppermissions-knownwiki' => 'Wiki der dei har ein konto:', |
— | — | @@ -15775,9 +15775,9 @@ |
15776 | 15776 | 'centralauth-mergeaccount-desc' => "[[Special:MergeAccount|A fond ansema vàire cont]] për l'identificassion ùnica", |
15777 | 15777 | 'centralauth-merge-denied' => "Darmagi, a l'ha pa ël përmess d'acede a costa pàgina-sì.", |
15778 | 15778 | 'centralauth-merge-notlogged' => 'Për piasì <span class="plainlinks">[{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} ch\'a rintra ant ël sistema]</span> për controlé che sò cont a sio stait mës-cià coma ch\'as dev.', |
15779 | | - 'centralauth-merge-welcome' => "'''Sò cont a l'é ancor pa tramudà al sistema d'intrada unificà ëd {{MediaWiki:Centralauth-groupname}}.''' |
| 15779 | + 'centralauth-merge-welcome' => "'''Sò cont a l'é ancor pa tramudà al sistema d'intrada unificà ëd {{MediaWiki:Centralauth-groupname}}.''' |
15780 | 15780 | |
15781 | | -S'a decid ëd tramudé ij sò cont, a podrà dovré midem stranòm e ciav për intré an qualsëssìa wiki ëd {{MediaWiki:Centralauth-groupname}} an qualsëssìa dle lenghe disponìbij. |
| 15781 | +S'a decid ëd tramudé ij sò cont, a podrà dovré midem stranòm e ciav për intré an qualsëssìa wiki ëd {{MediaWiki:Centralauth-groupname}} an qualsëssìa dle lenghe disponìbij. |
15782 | 15782 | |
15783 | 15783 | Se cheidun d'àutr a l'avèissa gia sërnusse lë stranòm dzora a n'àutr sit, sòn a-j darìa gnun fastudi, ma pì anans a-j darìa a tuti la possibilità d'arzòlve ël problema ansema a j'aministrator.", |
15784 | 15784 | 'centralauth-merge-step1-title' => "Anandié l'unificassion djë stranòm", |
— | — | @@ -16688,7 +16688,7 @@ |
16689 | 16689 | |
16690 | 16690 | Încă nu s-a operat nicio modificare asupra conturilor dumneavoastră.', |
16691 | 16691 | 'centralauth-merge-dryrun-or' => "'''sau'''", |
16692 | | - 'centralauth-merge-dryrun-home' => 'Sistemul de migrare nu a putut confirma că sunteţi deţinătorul contului care vă foloseşte numele de utilizator pe wiki-ul de reşedinţă. |
| 16692 | + 'centralauth-merge-dryrun-home' => 'Sistemul de migrare nu a putut confirma că sunteţi deţinătorul contului care vă foloseşte numele de utilizator pe wiki-ul de reşedinţă. |
16693 | 16693 | |
16694 | 16694 | Un alt wiki a fost fost determinat ca fiind contul de reşedinţă pentru numele dumneavoastră de utilizator; urmaţi legătura de mai jos şi autentificaţi-vă acolo pentru a încheia procesul de migrare a contului.', |
16695 | 16695 | 'centralauth-merge-step3-title' => 'Creează cont unificat', |
— | — | @@ -17172,12 +17172,12 @@ |
17173 | 17173 | 'centralauth-merge-notlogged' => 'Бука диэн, <span class="plainlinks">[{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} ааккын эт]</span>, оччоҕо ааттарыҥ холбонууларын туругун көрүөҥ.', |
17174 | 17174 | 'centralauth-merge-welcome' => "'''Эн аатыҥ {{MediaWiki:Centralauth-groupname}} бырайыактарыгар киирэр биир аат тиһигэр өссө киирэ илик''' |
17175 | 17175 | |
17176 | | -Ааттаргын онно киллэрэр түгэҥҥэр, биир аатынан уонна киирии тылынан {{MediaWiki:Centralauth-groupname}} ханнык баҕарар саайтарыгар киирэр кыахтаныаҥ. |
| 17176 | +Ааттаргын онно киллэрэр түгэҥҥэр, биир аатынан уонна киирии тылынан {{MediaWiki:Centralauth-groupname}} ханнык баҕарар саайтарыгар киирэр кыахтаныаҥ. |
17177 | 17177 | |
17178 | 17178 | Өскө ким эрэ эн ааккын атын бырайыакка ылбыт буоллаҕына бу дьайыы кинини таарыйыа суоҕа. Кэлин бу түгэни бэйэтин кытта эбэтэр дьаһабылы кытта быһаарсыаххын сөп.", |
17179 | 17179 | 'centralauth-merge-step1-title' => 'Бэлиэтэммит ааттары холбууру саҕалаа', |
17180 | 17180 | 'centralauth-merge-step1-detail' => 'Бука диэн киирии тылгын киллэр. |
17181 | | -Эн киирии тылыҥ уонна электроннай аадырыһыҥ атын вики бырайыактар ааттарын кытта тэҥнэниллиэ. |
| 17181 | +Эн киирии тылыҥ уонна электроннай аадырыһыҥ атын вики бырайыактар ааттарын кытта тэҥнэниллиэ. |
17182 | 17182 | Ханнык да уларытыы бэйэҥ бигэргэтэ иликкинэ олоххо киириэ суоҕа.', |
17183 | 17183 | 'centralauth-merge-step1-submit' => 'Аатым туһунан сибидиэнньэни бигэргэт', |
17184 | 17184 | 'centralauth-merge-step2-title' => 'Атын ааттары бигэргэт', |
— | — | @@ -17190,7 +17190,7 @@ |
17191 | 17191 | |
17192 | 17192 | Ааттарыҥ өссө да уларытылла иликтэр.', |
17193 | 17193 | 'centralauth-merge-dryrun-or' => "'''эбэтэр'''", |
17194 | | - 'centralauth-merge-dryrun-home' => 'Ааты көһөрүү (миграция) систиэмэтэ дьиэ-биикигэ ыйыллыбыт аат эйиэнэ буоларын туһунан бигэргэтиини кыайан ылбата. |
| 17194 | + 'centralauth-merge-dryrun-home' => 'Ааты көһөрүү (миграция) систиэмэтэ дьиэ-биикигэ ыйыллыбыт аат эйиэнэ буоларын туһунан бигэргэтиини кыайан ылбата. |
17195 | 17195 | |
17196 | 17196 | Ол гынан баран бу аакка атын биики-бырайыак дьиэ-биики быһыытынан булулунна; ону кытта сөбүлэһэр буоллаххына, ол аата ол биики бырайыакка баар ааты миэнэ диир түгэҥҥэр, аллара баар сигэннэн киирэн систиэмэҕэ ааккын билиһиннэр.', |
17197 | 17197 | 'centralauth-merge-step3-title' => 'Соҕотох ааты оҥоруу', |
— | — | @@ -17272,8 +17272,8 @@ |
17273 | 17273 | 'centralauth-admin-already-unmerged' => 'Маны көтүт $1, номнуо араарыллыбыт', |
17274 | 17274 | 'centralauth-admin-unmerge-success' => '$1 аат ситиһиилээхтик {{PLURAL:$1|араарылынна|араарылыннылар}}', |
17275 | 17275 | 'centralauth-admin-delete-title' => 'Ааты сот', |
17276 | | - 'centralauth-admin-delete-description' => 'Сүрүн ааты сотуу туох баар бу аакка сыһыаннаах туруоруулары соторго, атын ааттар арахсалларыгар уонна сүрүн аат босхолоноругар тиэрдиэҕэ, атын кыттааччы бу ааты иҥэриниэн сөп буолуоҕа. |
17277 | | -Атын локальнай ааттар сүтүөхтэрэ суоҕа. |
| 17276 | + 'centralauth-admin-delete-description' => 'Сүрүн ааты сотуу туох баар бу аакка сыһыаннаах туруоруулары соторго, атын ааттар арахсалларыгар уонна сүрүн аат босхолоноругар тиэрдиэҕэ, атын кыттааччы бу ааты иҥэриниэн сөп буолуоҕа. |
| 17277 | +Атын локальнай ааттар сүтүөхтэрэ суоҕа. |
17278 | 17278 | Локальнай ааттар урукку киирии тылларын төннөрүөхтэрэ.', |
17279 | 17279 | 'centralauth-admin-delete-button' => 'Бу ааты сот', |
17280 | 17280 | 'centralauth-admin-delete-success' => '"<nowiki>$1</nowiki>" аат ситиһиилээхтик сотулунна', |
— | — | @@ -18268,7 +18268,7 @@ |
18269 | 18269 | 'centralauth-merge-attempt' => "'''Wröigje dät ienroate Paaswoud mäd do uurblieuwene Benutserkonten...'''", |
18270 | 18270 | 'centralauth-attach-list-attached' => 'Dät globoale Benutserkonto mäd dän Noome „$1“ änthaalt do foulgjende Benutserkonten:', |
18271 | 18271 | 'centralauth-attach-title' => 'Benutserkonto bestäätigje', |
18272 | | - 'centralauth-attach-text' => 'Dit Benutserkonto wuude noch nit in n globoal Benutserkonto integrierd. |
| 18272 | + 'centralauth-attach-text' => 'Dit Benutserkonto wuude noch nit in n globoal Benutserkonto integrierd. |
18273 | 18273 | Wan dät globoale Benutserkonto uk fon die is, koast du ju Touhoopefierenge moakje, truch dät du hier dät Paaswoud fon dät globoale Benutserkonto ienrakst:', |
18274 | 18274 | 'centralauth-attach-submit' => 'Benutserkonto integrierje', |
18275 | 18275 | 'centralauth-attach-success' => 'Dät Benutserkonto wuude in dät globoale Benutserkonto integrierd.', |
— | — | @@ -18884,12 +18884,12 @@ |
18885 | 18885 | 'centralauth-merge-step2-submit' => 'ప్రవేశపు సమాచారాన్ని నిర్ధారించండి', |
18886 | 18886 | 'centralauth-merge-dryrun-complete' => 'ప్రస్తుతం ఉనికిలో ఉన్న ఖాతాలన్నిటినీ ఏకీకరించవచ్చు! |
18887 | 18887 | మీ ఖాతాల్లో ఇంకా మార్పులేమీ చెయ్యలేదు.', |
18888 | | - 'centralauth-merge-dryrun-incomplete' => 'మీరీ పనిని కొనసాగించవచ్చు. కానీ, కొన్ని ఖాతాలను ఆటోమాటిగ్గా ధృవీకరించలేకపోవడం వలన వాటిని ఇప్పుడు ఏకీకరించలేము. |
| 18888 | + 'centralauth-merge-dryrun-incomplete' => 'మీరీ పనిని కొనసాగించవచ్చు. కానీ, కొన్ని ఖాతాలను ఆటోమాటిగ్గా ధృవీకరించలేకపోవడం వలన వాటిని ఇప్పుడు ఏకీకరించలేము. |
18889 | 18889 | మీరు వీటిని తరువాత విలీనం చేసుకోవచ్చు. |
18890 | 18890 | |
18891 | 18891 | మీ ఖాతాల్లో ఇంకా మార్పులేమీ చెయ్యలేదు.', |
18892 | 18892 | 'centralauth-merge-dryrun-or' => "'''లేదా'''", |
18893 | | - 'centralauth-merge-dryrun-home' => 'మీ వాడుకరిపేరుకి ప్రధాన వికీ ఖాతా యొక్క యజమాని మీరే అని ఏకీకృత వ్యవస్థ నిర్ధారించలేకున్నది. |
| 18893 | + 'centralauth-merge-dryrun-home' => 'మీ వాడుకరిపేరుకి ప్రధాన వికీ ఖాతా యొక్క యజమాని మీరే అని ఏకీకృత వ్యవస్థ నిర్ధారించలేకున్నది. |
18894 | 18894 | |
18895 | 18895 | మీ వాడుకరిపేరుకి ప్రధాన ఖాతా మరొక వికీ అని తేలింది; కింది లింకుని అనుసరించి అక్కడ లోనికి ప్రవేశించి మీ ఖాతా ఏకీకరణను పూర్తిచేయండి.', |
18896 | 18896 | 'centralauth-merge-step3-title' => 'ఏకీకృత ఖాతాని సృష్టించండి', |
— | — | @@ -19016,8 +19016,8 @@ |
19017 | 19017 | 'centralauth-rightslog-entry-setchange' => "''$1'' లోని వికీలు మార్చబడ్డాయి: కలిపినవి: $2; తీసేసినవి: $3", |
19018 | 19018 | 'globalgroupmembership' => 'సార్వత్రిక గుంపుల్లో సభ్యత్వం', |
19019 | 19019 | 'globalgrouppermissions' => 'సార్వత్రిక గుంపు నిర్వహణ', |
19020 | | - 'centralauth-globalgroupperms-grouplist' => 'కింది సార్వత్రిక గుంపులు తయారయి ఉన్నాయి. |
19021 | | -వీటిని చూడటమే కాక, మీకు అనుమతి వుంటే వాటిలో మార్పులు చెయ్యవచ్చు. |
| 19020 | + 'centralauth-globalgroupperms-grouplist' => 'కింది సార్వత్రిక గుంపులు తయారయి ఉన్నాయి. |
| 19021 | +వీటిని చూడటమే కాక, మీకు అనుమతి వుంటే వాటిలో మార్పులు చెయ్యవచ్చు. |
19022 | 19022 | గుంపుకు ఉన్న అనుమతులను తీసివేయడం ద్వారా ఆ గుంపును తొలగించవచ్చు.', |
19023 | 19023 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|అనుమతులను చూడు, మార్చు]])', |
19024 | 19024 | 'centralauth-existinggroup-legend' => 'ప్రస్తుతం ఉన్న గుంపులు', |
— | — | @@ -19085,7 +19085,7 @@ |
19086 | 19086 | Агар номи корбарии шумо қаблан дар лоиҳаи дигаре тавассути шахси дигаре истифода шуда бошад, ин кор боиси халалрасонӣ ба онҳо намешавад, балки ба шумо имконеро медиҳад, ки баъдан ин мушкилро бо кӯмаки онҳо ё як мудир ҳал кунед.", |
19087 | 19087 | 'centralauth-merge-step1-title' => 'Оғози якка кардани ҳисобҳои корбарӣ', |
19088 | 19088 | 'centralauth-merge-step1-detail' => 'Лутфан гузарвожаи ҳисобатонро ворид кунед. |
19089 | | -Гузарвожа ва нишонаи почтаи электронии сабтшудаи бо ҳисобҳои корбарӣ викиҳои дигаре муқоиса мешавад, то аз мутобиқати онҳо итминон ҳосил гардад. |
| 19089 | +Гузарвожа ва нишонаи почтаи электронии сабтшудаи бо ҳисобҳои корбарӣ викиҳои дигаре муқоиса мешавад, то аз мутобиқати онҳо итминон ҳосил гардад. |
19090 | 19090 | То замоне, ки шумо таъйид накунед, ки ҳама чиз дуруст аст, тағйир сурат нахоҳад гирифт.', |
19091 | 19091 | 'centralauth-merge-step1-submit' => 'Тасдиқи иттилооти вуруд ба систем', |
19092 | 19092 | 'centralauth-merge-step2-title' => 'Тасдиқи ҳисобҳои корбарии бештар', |
— | — | @@ -19252,7 +19252,7 @@ |
19253 | 19253 | 'centralauth-merge-notlogged' => 'Lutfan <span class="plainlinks">[{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} ba sistem vorid şaved]</span> to az idƣomi hisobhoi korbariaton itminon hosil kuned.', |
19254 | 19254 | 'centralauth-merge-step1-title' => 'Oƣozi jakka kardani hisobhoi korbarī', |
19255 | 19255 | 'centralauth-merge-step1-detail' => "Lutfan guzarvoƶai hisobatonro vorid kuned. |
19256 | | -Guzarvoƶa va nişonai poctai elektroniji sabtşudai bo hisobhoi korbarī vikihoi digare muqoisa meşavad, to az mutobiqati onho itminon hosil gardad. |
| 19256 | +Guzarvoƶa va nişonai poctai elektroniji sabtşudai bo hisobhoi korbarī vikihoi digare muqoisa meşavad, to az mutobiqati onho itminon hosil gardad. |
19257 | 19257 | To zamone, ki şumo ta'jid nakuned, ki hama ciz durust ast, taƣjir surat naxohad girift.", |
19258 | 19258 | 'centralauth-merge-step1-submit' => 'Tasdiqi ittilooti vurud ba sistem', |
19259 | 19259 | 'centralauth-merge-step2-title' => 'Tasdiqi hisobhoi korbariji beştar', |
— | — | @@ -19541,7 +19541,7 @@ |
19542 | 19542 | 'centralauth-finish-login' => 'Sessiýa açyş', |
19543 | 19543 | 'centralauth-finish-send-confirmation' => 'Paroly e-poçta bilen iber', |
19544 | 19544 | 'centralauth-finish-noconfirms' => 'Bu parol bilen hiç bir hasaby tassyklap bolmady.', |
19545 | | - 'centralauth-finish-incomplete' => 'Bu paroly ulanmak arkaly birnäçe hasap birleşdirildi. |
| 19545 | + 'centralauth-finish-incomplete' => 'Bu paroly ulanmak arkaly birnäçe hasap birleşdirildi. |
19546 | 19546 | Beýleki hasaplar heniz tassyklanylmady.', |
19547 | 19547 | 'centralauth-attach-list-attached' => '"$1" atly birleşen hasap aşakdaky hasaplary öz içine alýar:', |
19548 | 19548 | 'centralauth-attach-title' => 'Hasaby tassykla', |
— | — | @@ -19660,7 +19660,7 @@ |
19661 | 19661 | 'centralauth-editgroup-perms' => 'Bellenen rugsatlar:', |
19662 | 19662 | 'centralauth-editgroup-reason' => 'Sebäp:', |
19663 | 19663 | 'centralauth-editgroup-success' => 'Topar rugsatlary üýtgedildi', |
19664 | | - 'centralauth-editgroup-success-text' => '$1 topary üçin topar rugsatlaryny şowly üýtgetdiňiz. |
| 19664 | + 'centralauth-editgroup-success-text' => '$1 topary üçin topar rugsatlaryny şowly üýtgetdiňiz. |
19665 | 19665 | [[Special:GlobalGroupPermissions|Topar dolandyryşyna gaýdyp baryň]]', |
19666 | 19666 | 'centralauth-editgroup-editsets' => '([[Special:EditWikiSets|redaktirle]])', |
19667 | 19667 | 'centralauth-globalgrouppermissions-knownwiki' => 'Olaryň hasaby bar bolan wiki:', |
— | — | @@ -19883,7 +19883,7 @@ |
19884 | 19884 | 'globalgroupmembership' => 'Kasapian sa pandaigdigang mga pangkat', |
19885 | 19885 | 'globalgrouppermissions' => 'Pamamahala ng pandaigdigang pangkat', |
19886 | 19886 | 'centralauth-globalgroupperms-grouplist' => 'Naisaayos na ang sumusunod na pandaigdigang mga pangkat. |
19887 | | -Maaari mong tingnan at baguhin ang mga pahintulot na nakatakda sa isang pangkat, kung mayroon kang pahintulot. |
| 19887 | +Maaari mong tingnan at baguhin ang mga pahintulot na nakatakda sa isang pangkat, kung mayroon kang pahintulot. |
19888 | 19888 | Maaaring burahin ang isang pangkat sa pamamagitan ng pagtatanggal ng lahat ng mga karapatan nito.', |
19889 | 19889 | 'centralauth-globalgroupperms-grouplistitem' => '$1 ([[Special:GlobalGroupPermissions/$2|pagtingin/pagbago]])', |
19890 | 19890 | 'centralauth-globalgroupperms-nogroups' => 'Walang binigyang-kahulugang mga pandaigdigang pangkat.', |
— | — | @@ -20546,14 +20546,14 @@ |
20547 | 20547 | 'centralauth-mergeaccount-desc' => '[[Special:MergeAccount|Unifica più account]] par el Login Unico', |
20548 | 20548 | 'centralauth-merge-denied' => 'No te ghè i parmessi necessari par entrar su sta pagina.', |
20549 | 20549 | 'centralauth-merge-notlogged' => 'Par piaser, de <span class="plainlinks">[{{fullurl:{{#special:UserLogin}}|returnto={{#special:MergeAccount}}}} fà el login]</span> par verificar se el processo de unificazion de le to utenze el xe conpleto.', |
20550 | | - 'centralauth-merge-welcome' => "'''El to account utente no'l xe gnancora stà inportà nel sistema de identificazion unificà de {{MediaWiki:Centralauth-groupname}}.''' |
| 20550 | + 'centralauth-merge-welcome' => "'''El to account utente no'l xe gnancora stà inportà nel sistema de identificazion unificà de {{MediaWiki:Centralauth-groupname}}.''' |
20551 | 20551 | |
20552 | | -Se te decidi de unificar i to account, te podarè doparar el stesso nome utente e la stessa password par entrar in tuti quanti i progeti wiki de {{MediaWiki:Centralauth-groupname}} in tute le lengue disponibili. |
| 20552 | +Se te decidi de unificar i to account, te podarè doparar el stesso nome utente e la stessa password par entrar in tuti quanti i progeti wiki de {{MediaWiki:Centralauth-groupname}} in tute le lengue disponibili. |
20553 | 20553 | |
20554 | 20554 | Se qualchedun altro el s'à zà tolto el to nome utente su un altro sito, questo no'l lo disturbarà, ma l'unificazion la te darà a ti la possibilità de sotoporghe in futuro el problema a l'altro utente o a un aministrador.", |
20555 | 20555 | 'centralauth-merge-step1-title' => "Intaca l'unificazion dei login", |
20556 | 20556 | 'centralauth-merge-step1-detail' => "Par piaser inserìssi qua la to password. |
20557 | | -La to password e l'indirizo e-mail registrà i sarà desso controlà sui account in altre wiki par confermar che i corisponda. |
| 20557 | +La to password e l'indirizo e-mail registrà i sarà desso controlà sui account in altre wiki par confermar che i corisponda. |
20558 | 20558 | No sarà fata nissuna modifica prima de la to conferma che tuto quanto xe in regola.", |
20559 | 20559 | 'centralauth-merge-step1-submit' => 'Conferma le informazion par el login', |
20560 | 20560 | 'centralauth-merge-step2-title' => 'Conferma altri account', |
Index: trunk/extensions/CentralAuth/renaming.txt |
— | — | @@ -3,4 +3,3 @@ |
4 | 4 | * Never change the established name of a user account |
5 | 5 | * To "rename", create a new account and migrate the settings. |
6 | 6 | * -question- -> what about reattribution? |
7 | | - |