扩展:AntiSpoof

From mediawiki.org
This page is a translated version of the page Extension:AntiSpoof and the translation is 83% complete.
MediaWiki扩展手册
AntiSpoof
发行状态: 稳定版
实现 用户活动
描述 防止创建混淆的用户名。
作者 Brooke Vibber留言
兼容性政策 快照跟随MediaWiki发布。 master分支不向后兼容。
MediaWiki >= 1.42
数据库更改
Composer mediawiki/anti-spoof
spoofuser
许可协议 GNU通用公眾授權條款2.0或更新版本
下載
  • $wgAntiSpoofProhibitedCharacters
  • $wgAntiSpoofAccounts
  • override-antispoof
季度下載量 82 (Ranked 72nd)
正在使用的公开wiki数 2,675 (Ranked 190th)
前往translatewiki.net翻譯AntiSpoof扩展
問題 开启的任务 · 报告错误

AntiSpoof(反混淆、反用户名混淆)是防止创建混淆用户名的扩展。 它可以阻止使用混合脚本创建令人困惑和类似用户名的帐户。

例如,如果用户John Doe已经注册,则扩展将阻止尝试注册:

  • joHn dOE (不同地方的大寫字母)
  • Jοhn Doe (Jοhn中的"ο"是希腊语的小写字母。)
  • John Dоe (Dоe中的"о"是西里尔字母中小写的O。)
  • Јohn Doe (Јohn中的"Ј"是西里爾大寫字母Je。)
  • John Đoe (Đoe中的"Đ"是帶筆劃的拉丁文大寫字母D。)
  • Jóhn Doe (Jóhn中的"ó"是帶銳角的拉丁文小寫字母O。)
  • John ​Doe (在Doe之前有一個零寬度空間)
  • Jøhn Doe (Jøhn中的"ø"是斯堪的納維亞語oe。)
  • J0hn Doe ("0"是阿拉伯数字0)

等等

安裝

  • 下载文件,并将其放置在您extensions/文件夹中的AntiSpoof目录内。
    开发者和代码贡献人员应从Git安装扩展,输入:cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/AntiSpoof
  • 只有從git安裝才运行Composer来安装PHP依赖,通过发行composer install --no-dev至扩展目录。 (参见工單T173141了解潜在问题。)
  • 将下列代码放置在您的LocalSettings.php 的底部:
    wfLoadExtension( 'AntiSpoof' );
    
  • 运行更新脚本,它将自动创建此扩展必须依赖的数据库表。
  • 如果用户账户存储在一个共享的数据库中,则添加:
$wgSharedTables[] = 'spoofuser';
  • Run the batchAntiSpoof.php script from the command line to pre-populate the spoofuser table with your wiki's existing usernames.
php maintenance/run.php AntiSpoof:batchAntiSpoof.php
  • Yes 完成 – 在您的wiki上导航至Special:Version,以验证已成功安装扩展。
  • 要驗證它是否正常工作,請嘗試為用戶名“Adm1n”創建一個帳戶;大多數維基都有一個“管理員”(Admin)帳戶,因此反混淆應該拒絕這個相似的用戶名,並顯示類似“名稱Adm1n與現有帳戶太相似:管理員(Admin)”的消息。

When installing from Git, please note that this extension requires Composer.

So, after installation from Git change to the directory containing the extension e.g. "../extensions/AntiSpoof/" and run composer install --no-dev, or when updating: composer update --no-dev.

Alternatively as well as preferably add the line "extensions/AntiSpoof/composer.json" to the "composer.local.json" file in the root directory of your wiki like e.g.

{
	"extra": {
		"merge-plugin": {
			"include": [
				"extensions/AntiSpoof/composer.json"
			]
		}
	}
}


參見

  • Equivset (provides the equivalence sets used by AntiSpoof)