Extension:OATHAuth
![]() リリースの状態: 安定 |
|
---|---|
![]() |
|
実装 | 利用者権限 , 特別ページ , ページの操作 |
説明 | ログインする際の二段階認証を可能にします。 |
作者 | Ryan Lane |
最新バージョン | 継続的な更新 |
互換性の方針 | MediaWiki とともにリリースされるスナップショット。 master には後方互換性がありません。 |
MediaWiki | 1.29+ |
データベースの変更 | はい |
テーブル | oathauth_users |
ライセンス | GPL-2.0-or-later AND GPL-3.0-or-later |
ダウンロード | |
|
|
|
|
Quarterly downloads | 84 (Ranked 84th) |
Public wikis using | 1,459 (Ranked 205th) |
translatewiki.net で翻訳を利用できる場合は、OATHAuth 拡張機能の翻訳にご協力ください | |
問題点 | 未解決のタスク · バグを報告 |
OathAuth拡張機能で、二段階認証に対応。 デフォルトでは、これにはtime-based one-time password (TOTP) の実装が含まれており、ユーザーは携帯電話やデスクトップアプリケーションから2FAコードを生成できるようになっています。 クライアントサポートは、ほとんどのフィーチャーフォン、スマートフォン、デスクトップで利用可能です。
使用法
Two-factor authentication上のヘルプページは利用者のためにこの拡張機能の使い方に関する情報を提供します。 ただし、特別ページでは利用者にも案内しています。
インストール
- ダウンロードして、ファイルを
extensions/
フォルダー内のOATHAuth
という名前のディレクトリ内に配置します。
Developers and code contributors should install the extension from Git instead, using:cd extensions/
git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/OATHAuth - Gitでのインストールの場合のみ、PHPの依存関係をインストールするためComposerを実行します。 (合併症の可能性についてはタスク T173141を参照。)
- 以下のコードを LocalSettings.php ファイルの末尾に追加します:
wfLoadExtension( 'OATHAuth' );
- 更新スクリプトを実行します。このスクリプトは、この拡張機能が必要とするデータベーステーブルを自動的に作成します。
- 必要に応じて設定します。
- It is strongly recommended to setup caching when using OATHAuth. This will improve performance, but also the security of your wiki if you're using OATHAuth. If you are only running one application/web server and have php-apcu installed, and no specific cache configured, MediaWiki will likely fallback to using APCu. If you are using multiple application/web server it is advised to setup local cluster caching that can be used by all hosts. Examples include Memcached .
- 完了 – ウィキの「Special:Version」に移動して、拡張機能が正しくインストールされたことを確認します。
設定の構成
パラメーター
構成フラグ | 既定値 | 説明 |
---|---|---|
$wgOATHAuthWindowRadius
|
4
|
有効であるべき各方向のトークン・ウィンドウの数。
実質的に |
$wgOATHAuthDatabase
|
false
|
データベースのドメイン。 複数のデータベースでのみ使用されます。 |
$wgOATHAuthSecret
|
false
|
全暗号化キーの派生元であるこのWikiの基本OATHAuthシークレット。
|
$wgOATHAuthAccountPrefix
|
false
|
OATHAuthのアカウント名に使用される接頭辞と、アカウントに適用される発行者。
|
$wgOATHExclusiveRights
|
[]
|
Set of permissions that are revoked from users who did not log in using two-factor authentication. |
$wgOATHRequiredForGroups
|
[]
|
Sets a list of user groups that are required to have two-factor authentication enabled. Use 'user' if you want all logged in users to be required to have two-factor authentication enabled. |
OATHAuth also adds a key to the $wgRateLimits array to define rate limits for authentication attempts:
'badoath' => [
'&can-bypass' => false,
'user' => [ 10, 60 ],
'user-global' => [ 10, 60 ],
]
user-global
キーはバージョン1.35からでしか使えないことに注意してください。
Earlier version have to rely on user
and perhaps ip-all
.
完全な一覧は、$wgRateLimits
の説明文書を参照してください。
利用者権限
- OATHAuthへのアクセス権限
Users should be given access to the oathauth-enable
user right so that they can enable it at Special:OATHAuth (a link to which appears at Special:Preferences).
$wgGroupPermissions['user']['oathauth-enable'] = true;
上記から、全登録利用者にOATHAuthを有効にするためのアクセス権限が付与されます。
管理
- ユーザートークンのリセット
In the event that a user both loses their token generator AND the recovery tokens; two-factor authentication may be removed from the user by deleting their row from the oathauth_users
database table.
Alternatively, a sysadmin with shell access may type on a command line cd /path/to/mediawiki/extensions/OATHAuth/maintenance/
and then execute php disableOATHAuthForUser.php "username"
where "username"
is the user to have 2FA disabled.
関連項目
- Wikimedia Security Team/Two-factor Authentication for CentralAuth wikis
- Two-factor authentication (TFA)
- Extension:WebAuthn
- Initiative for Open Authentication (OATH)
この拡張機能は 1 つ以上のウィキメディアのプロジェクトで使用されています。 これはおそらく、この拡張機能が安定していて高いトラフィックのウェブサイトでも十分に動作することを意味します。 この拡張機能がインストールされている場所を確認するには、ウィキメディアの設定ファイル CommonSettings.php および InitialiseSettings.php 内で、この拡張機能の名前を探してください。 特定のウィキにインストールされている拡張機能の完全な一覧は、そのウィキの Special:Version ページにあります。 |
この拡張機能は以下のウィキ ファーム/ウィキ ホスト/パッケージに含まれています: これは正式な一覧ではありません。 一部のウィキ ファーム/ウィキ ホスト/パッケージは、ここに記載されていなくてもこの拡張機能を含んでいる場合があります。 必ずご利用のウィキ ファーム、ウィキ ホスト、バンドルで確認してください。 |