Extension:GlobalBlocking/zh

Category:GPL licensed extensions/zh
GlobalBlocking
Category:Stable extensions/zh
Category:Special page extensions/zh, Category:User identity extensions/zh, API Category:API extensions/zh, Category:Database extensions/zh
描述 Allows IP addresses and accounts to be blocked on multiple wikis
作者 Andrew Garrett, Trust and Safety Product Team, Dreamy Jazz
快照跟随MediaWiki发布。
虚拟域 virtual-globalblocking
globalblocks
global_block_whitelist
GNU通用公眾授權條款2.0或更新版本
下載 Category:Extensions in Wikimedia version control/zh
  • $wgGlobalBlockingMassGlobalBlockMaxTargets
  • $wgGlobalBlockRemoteReasonUrl
  • $wgGlobalBlockingAllowedRanges
  • $wgGlobalBlockingMaximumIPsToRetroactivelyAutoblock
  • $wgApplyGlobalBlocks
  • $wgGlobalBlockingBlockXFF
  • $wgGlobalBlockingCentralWikiContentLanguage
  • $wgGlobalBlockingAutoblockExpiry
  • $wgGlobalBlockingEnableAutoblocks
  • $wgGlobalBlockingCentralWiki
  • $wgGlobalBlockingHideAutoblocksInGlobalBlocksAPIResponse
  • $wgGlobalBlockingCIDRLimit
  • globalblock
  • globalblock-whitelist
  • globalblock-exempt
前往translatewiki.net翻譯GlobalBlocking
Vagrant角色 globalblocking
問題 开启的任务 ·
Category:All extensions/zh
Category:Pages using deprecated NoteTA template#%20

GlobalBlocking擴充功能可讓擁有相應權限的用戶,在共享相同的globalblocking資料庫的群組中的所有維基上,封鎖某個IP地址、某些IP地址範圍、或某個帳戶(但「不包括」MediaWiki 1.43之前的帳戶)。 它旨在用於打擊跨維基的嚴重破壞和垃圾信息。

安裝

  • 下载,并将解压后的GlobalBlocking移动到extensions/目录中。
    开发者和代码贡献人员应从Git安装扩展,输入:
    cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalBlocking
    
  • 将下列放置在您的LocalSettings.php 的底部:
    wfLoadExtension( 'GlobalBlocking' );
    
  • 您還需要為此擴充功能創建一個專用的數據庫才能正常運行。 最低限度(所有維基都運行在同一主機上),您需要為全域表創建一個本地的資料庫。 通常,此資料庫會命名為globalblocking,但您可以選擇其他名稱。 例如,在維基媒體基金會的維基上,此表格位於名為centralauth的資料庫之中。
  • 授予所有資料庫的使用者在上述步驟中建立的資料庫上的完全權限(最低限度是SELECT, UPDATE, INSERT, DELETE)。
  • Do either of the following depending on the version of MediaWiki you are running:
    • 如果您運行的是MediaWiki 1.42或更高版本,請定義配置 $wgVirtualDomainsMapping['virtual-globalblocking'] = ['db' => 'globalblocking'];(將 globalblocking 替換為在上一步驟中創建的資料庫名稱)。 See Manual:$wgVirtualDomainsMapping for more detail on how this configuration value works.
    • 如果您運行的是MediaWiki 1.41或更早版本,請定義配置 $wgGlobalBlockingDatabase = 'dbname';,其中 dbname 將替換為您在上一步驟中創建的資料庫名稱。 如果您將資料庫命名為 globalblocking,則可以跳過此步驟。
  • Do either of the following depending on the version of MediaWiki you are using:
    • 如果您運行的是MediaWiki 1.44或更新版本,請在一個維基上執行update.php,這將創建您在上一步驟中定義的資料庫中的表格。
    • 如果您運行的是MediaWiki 1.43或更早版本,則在創建數據庫後,應將 tables-generated-globalblocks.sql 中的 SQL 導入全局封鎖數據庫。
  • 您還需要在每個本地資料庫上執行update.php,以添加擴充功能所需的本地表。
  • Yes 完成 – 在您的wiki上Special:Version,以验证已成功安装


描述
$wgApplyGlobalBlocks 是否遵守本維基上的全域封鎖。 這用於在一個維基上設置全局封鎖,但實際上並不在該維基上應用(即人們可以在該維基上對封禁提出異議)。
$wgGlobalBlockingBlockXFF The flag $wgGlobalBlockingBlockXFF, set to true by default, causes blocks to apply to all of the IP addresses in the X-Forwarded-For (XFF) header. Set this flag to false to disable this feature. For more details, see T25343.
$wgGlobalBlockingCIDRLimit Largest global rangeblocks allowed, set by CIDR prefix. The format is the same as $wgBlockCIDRLimit and the default values are /16 for IPv4 and /19 for IPv6, as with $wgBlockCIDRLimit.
$wgGlobalBlockingDatabase
MediaWiki版本:
1.41
The name of the database used to store the globalblocks table. This table is on a different database because only one table is used for all wikis in a wiki farm.
$wgGlobalBlockRemoteReasonUrl Full path to api.php to use to expand templates in block reasons.
$wgGlobalBlockingAllowedRanges A list of ranges or IP addresses which are exempted from all global blocks which target the ranges or IP addresses. This exemption does not apply to global account blocks (even if the user is on an exempt range or IP address).
$wgGlobalBlockingCentralWiki The ID of the central wiki where global blocks are performed. Used to provide a link to the global block log which is likely to have entries, instead of the local log which is unlikely to contain entries. If the value is false, then the local log is used.
$wgGlobalBlockingMaximumIPsToRetroactivelyAutoblock
MediaWiki版本:
1.43
The maximum number of IP addresses that can be retroactively autoblocked when a user is globally blocked and global autoblocking has been enabled for the global block.
$wgGlobalBlockingMassGlobalBlockMaxTargets
MediaWiki版本:
1.44
The maximum number of targets that can be globally blocked or unblocked in one use of Special:MassGlobalBlock.

API

Two API modules are provided, one to (un)block users, and another to view existing global blocks. They are documented at Extension:GlobalBlocking/API.

Usage

Globally (un)blocking

The following requires appropriate permissions, assigned by default to stewards, which by default can be added or removed by bureaucrats.

GlobalBlock

To make a global block:

  1. Go to Special:GlobalBlock.
  2. Enter the target you want to block. This can be an account post MediaWiki 1.43, an IPv4 address or range up to $wgGlobalBlockingCIDRLimit (by default /16, and also /16 hardcoded before that variable was introduced), or any IPv6 address or range up to $wgGlobalBlockingCIDRLimit (by default /19; /4 before that variable was introduced).
  3. You may decide you want to only block anonymous users, which can only be done for blocks on IPv4 or IPv6 addresses. To only block anonymous users, check the checkbox.
  4. Submit the form. The target of the block is now globally blocked on your wikis that opt in to the global blocking. Account creation is blocked (even if you selected "anonymous users only": phab:T42190), and the blocked user cannot edit any associated user talk pages on any wiki affected and opted in to the global block. If : is installed, globally blocked IP addresses are prohibited from viewing the abuse log if the particular wiki is opted in to the block.
GlobalUnblock

To remove a global block:

  1. Go to Special:GlobalUnblock and click "Remove a global block".
  2. Enter the target of the block you want to remove and the reason, and submit the form. The account, IP address, or IP range will no longer be globally blocked.
MassGlobalBlock
MediaWiki版本:
1.44

You can remove, modify, and create global blocks using Special:MassGlobalBlock for many targets at once. The first step of this form is to lookup the global block status of a list of targets provided in an input. Then you can use the form to globally block or globally unblock, with the relevant parameters applied to each target.

Local status

Administrators can disable the global block on the wiki where they have administrator rights. This is done through using the Special:GlobalBlockStatus page.

See also

Category:Extensions used on Wikimedia/zh#GlobalBlocking/zh Category:Extensions for data exchange with other local wikis/zh
Category:API extensions/zh Category:All extensions/zh Category:CentralAuthInfoFields extensions/zh Category:ContributionsToolLinks extensions/zh Category:Database extensions/zh Category:Extensions for data exchange with other local wikis/zh Category:Extensions in Wikimedia version control/zh Category:Extensions included in Miraheze/zh Category:Extensions included in Telepedia/zh Category:Extensions included in WikiForge/zh Category:Extensions included in wiki.gg/zh Category:Extensions used on Wikimedia/zh Category:GPL licensed extensions/zh Category:GetBlockErrorMessageKey extensions/zh Category:GetLogTypesOnUser extensions/zh Category:GetUserBlock extensions/zh Category:LoadExtensionSchemaUpdates extensions/zh Category:OtherBlockLogLink extensions/zh Category:Pages using deprecated NoteTA template Category:SpecialContributionsBeforeMainOutput extensions/zh Category:Special page extensions/zh Category:SpreadAnyEditBlock extensions/zh Category:Stable extensions/zh Category:UserIsBlockedGlobally extensions/zh Category:UserMergeAccountFields extensions/zh Category:User identity extensions/zh