Extension:CentralAuth/ja

CentralAuthはグローバルアカウントを複数のプロジェクトで共有することを認めます. この拡張機能は7個の新しい特別ページを追加します: Special:AutoLogin (一覧に表示されない特別ページ), Special:CentralAuth, Special:GlobalGroupMembership, Special:GlobalGroupPermissions, Special:WikiSets, Special:GlobalUsers, Special:MergeAccount

CentralAuthのバージョンをダウンロードするには、ご利用のMediaWikiのバージョンに対応させるよう推奨されます.

インストール
CentralAuth のインストールと使用の前提条件は、以下の セットアップ節を参照してください. CentralAuth を有効にする準備ができたら、次に以下の指示に従ってください:


 * 1) 最新のスナップショットをダウンロードして、 ディレクトリに展開します.
 * 2) データベースを選択し、CentralAuthデータベーステーブルを作成してください.  使用するデータベースは既存でも、新規作成することもできす. 拡張機能の使用する規定のデータベースの名前は です (以下をご参照ください).  このデータベースを使用し、次に を実行します.
 * 3) * を使用する場合は、グローバルな   テーブルを作成する櫃行があります (ウィキを問わず見た目が似た利用者名を除外するため. ) これを行う方法の一つとして、ローカルwikiのデータベースから テーブルのダンプを作成し、新しいにインポートします.
 * 4) の追加先は、ご利用のウィキ単位で   に、もしくはご利用のウィキごとに   に含まれた他の PHP ファイルです.
 * 5) これで拡張機能が有効になるはずです.

ここで紹介するサンプルシェルとSQLコマンドは、CentralAuth のデータベースを作成してそこに spoofuser テーブルを転写してから、既存のユーザーデータをそこへ移行するために使います. ご利用のウィキのインストール形態に合わせて、$wgDBname と $wgDBuser を該当する値に置換します.

新規データベースを作成 (この段階はオプション、既存のデータベースを使うなら本項目は飛ばしてテーブル作成の手順へ進みます):

以下の記述は現時点の作業ディレクトリがご利用の MediaWiki インスタレーションであることを前提にします (ご利用の CentralAuth ディレクトリではない点にご注意. ) 中央認証テーブルを作成します（ の使用が推奨されます）. シェルアクセスができない場合は、PHPMyAdminのようなデータベース管理ツールを使用して をインポートすることもできます.

If AntiSpoof is installed, create the table via (Alternatively, you can copy an existing AntiSpoof table if you want to keep previous entries):

利用者移行スクリプトの実行

Walkthrough is a more user-friendly setup than the instructions below.

セットアップ
First, you'll need to configure your wiki family using, or CentralAuth can't be used for your wiki family. This includes setting and assigning it to, and  (minimum is ,  and ). Follow the examples carefully. Make sure that you put the configuration code after the line in. If you are creating a new wiki family, bear in mind that it may be easier if the databases for the wikis in each group have the same suffix (e.g. hypothetical databases,  ,  , etc., pertaining to wikis belonging to the same group, all have the suffix " ").

After installing the extension, you have to gather some data in the CentralAuth database. In order to retroactively set up global accounts, you will have to run the and  scripts. The first one stores information about your wikis in the CentralAuth database, while the second one uses automatic migration heuristics to generate global accounts. A user can merge their accounts manually via Special:MergeAccount. Dry runs can be used for testing purposes.

To enable global groups, you will have to make an entry into the  table in your CentralAuth database, with   and (for access to the group management interface). 使用することが推奨されるサンプルクエリー :. Then, run  to promote local stewards to global steward status.

There are various settings you may wish to modify (e.g. whether to provide single sign-on across a whole domain) listed in. In particular, you will want to override the default value of if your CentralAuth database is named something other than. Make sure you put such settings after the  line in , e.g.:

"SUL2" behavior
In July 2013 WMF changed its approach to logging users into multiple wikis. When configured for this new approach, after successful login and account creation CentralAuth redirects to  on a "central login wiki", which sets cookies on that wiki and then redirects back to the logged-into wiki. It omits the "login/account creation success" page, instead redirecting back to the "returnto" page that the user was originally on. It places 1x1 pixel images in the footer of that page, in place of the icons formerly used on the "login/account creation success" page.

The settings for this are, roughly,

is the id (usually the database-name) of the wiki to which CentralAuth will redirect on login and create account.

means account creation will create a new global account (this parameter was deleted from MediaWiki 1.27).

Simulating SUL2 behavior on a single-instance development machine
You can simulate this new behavior on a single-instance development machine. You can set  so CentralAuth makes its HTTP redirect requests to your same local wiki. This will not exercise central login properly, but will activate its " " behavior. CentralAuthは、グローバル利用者名用の独自の データベースを使用します.

To determine the URL on the login wiki, CentralAuth uses WikiMap which assumes a wiki farm has been configured using. Configuration setup (in ) is very flexible; one way to set up a dummy single-wiki  in   is:

This is in addition to the settings in #"SUL2" behavior above.

キャッシュの問題
最良の結果を得るために、memcachedの使用が推奨されます. If you have only a single server, accelerator caches like APCu can also work, but do not use them if you have multiple servers. If you have no cache set up (i.e. ) for, or are using , then you need to make sure all your wikis use the same caching table.

By default, each wiki in your wiki farm will use the  table in its own database (with its own db prefix) when  is set to   or.

これをCentralAuthで正常に動作させるために、中央のキャッシュテーブルを使用するようwikiを設定する必要があります.

If you want to make a central caching table in the  database (and assuming one of your existing wikis has a database name of  ), run code like the following to copy the table to your other database:

次に、以下の設定を全てのWikiに行い、中央のWikiが使用されるようにします :

使用法
Allows for a single-user login (SUL) system using MediaWiki's AuthPlugin system. User creation and login is done globally using one central user table across all wikis. Note that local user accounts are automatically created on account creation/login however.

This extension also implements global user groups, to which global accounts can belong to.

利用者権限
CentralAuth defines several new user rights:

Single-user login (SUL)
A user with an account on more than one wiki may use Special:MergeAccount to create their global user account, which can then be used on any wiki. Users with the  permission (given to stewards by default) can undo a merging of a global account, where the passwords are all reset back to the pre-merge setting. User accounts can now also be renamed globally.

グローバルユーザーをロックして非表示にする
A global account can be locked or hidden by a user with the  and   permissions, respectively, given to the local group 'stewards' by default. A locked global account will be immediately logged out of any session on any wiki it is currently logged in to. A hidden global account's username is not visible in any logs except the global account log.

Wikiのセット
A wiki set is a group of wikis specified by a user with the  right. Sets can be opt-in (wikis are not in it by default) or opt-out (wikis are in it unless opted out).

グローバル利用者グループ
Once you have enabled global user groups as described in the installation section, a migrated steward can use the Special:GlobalGroupPermissions interface to configure global user groups, and their rights. A global user group is active on all wikis (the users in it have its rights on all the wikis) by default, unless the group has been specified to only be active on a specific wiki set (the users in the group only have the rights if they are on a wiki in the set). Global group permissions are not listed at Special:ListUsers, but instead Special:GlobalUsers. They are assigned by a user with the  permission (by default the global group  ), and give the specified rights to the user even if the local rights defined by  do not do so.

ライセンスとダウンロード
The extension is available under the GNU General Public License 2.0 or later, and can be downloaded from Git, or accessed via the.

The software is provided as-is. Updates will be made according to the needs of Wikimedia wikis; or where critical vulnerabilities are discovered.

API
を参照

関連項目

 * Single login specifications on Meta-Wiki
 * Help:Unified login on Meta-Wiki
 * w:Wikipedia:Integrated watchlists
 * CentralAuth制御フロー
 * Stuck global renames
 * CentralAuth制御フロー
 * Stuck global renames