Extension:BlocageGlobal
Appearance
GlobalBlocking État de la version : stable |
|
---|---|
Implémentation | Page spéciale , Identité de l'utilisateur , API , Base de données |
Description | Allows IP addresses and accounts to be blocked on multiple wikis |
Auteur(s) | Andrew Garrett, Trust and Safety Product Team, Dreamy Jazz |
Politique de compatibilité | Versions ponctuelles alignées avec MediaWiki. Le master n'est pas compatible arrière. |
MediaWiki | 1.39 and later |
Modifie la base de données |
Oui |
Domaine virtuel | virtual-globalblocking |
Tables | globalblocks global_block_whitelist |
Licence | Licence publique générale GNU v2.0 ou ultérieur |
Téléchargement | |
|
|
|
|
Téléchargements trimestriels | 84 (Ranked 61st) |
Utilisé par les wikis publics | 1,015 (Ranked 250th) |
Traduire l’extension GlobalBlocking sur translatewiki.net si elle y est disponible | |
Rôle Vagrant | globalblocking |
Problèmes | Tâches ouvertes · Signaler un bogue |
L'extension GlobalBlocking permet à un utilisateur disposant des autorisations appropriées de bloquer une adresse IP ou une plage d'adresses IP (mais pas les comptes antérieurs à MediaWiki 1.43) sur tous les wikis d'un groupe partageant la même base de données globalblocking
.
Il est destiné à être utilisé pour lutter contre le vandalisme et le spam inter-wiki graves.
Installation
- Téléchargez et placez le(s) fichier(s) dans un répertoire appelé
GlobalBlocking
dans votre dossierextensions/
.
Les développeurs et les contributeurs au code doivent à la place installer l'extension à partir de Git en utilisant:cd extensions/
git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalBlocking - Ajoutez le code suivant à la fin de votre fichier LocalSettings.php :
wfLoadExtension( 'GlobalBlocking' );
- You will also need to create a dedicated database for this extension to work. At a minimum (all wikis running on the same host), you need to create a local database for the global tables. Usually this database is named
globalblocking
, but you can choose a different name. For example, on WMF wikis this table is on a database namedcentralauth
. - Grant all database users that your wikis run as full permissions on the database created in the above step (at a minimum,
SELECT, UPDATE, INSERT, DELETE
). - Do either of the following depending on the version of MediaWiki you are running:
- If you run MediaWiki 1.42 or above, define the configuration
$wgDatabaseVirtualDomains['virtual-globalblocking'] = 'globalblocking';
(replacingglobalblocking
with the name of the database created in the steps above). See Manual:$wgVirtualDomainsMapping for more detail on how this configuration value works. - If you run MediaWiki 1.41 or below, define the configuration
$wgGlobalBlockingDatabase = 'dbname';
wheredbname
is replaced with the name of the database you created in the steps above. If you called your databaseglobalblocking
then you can skip this step.
- If you run MediaWiki 1.42 or above, define the configuration
- After creating the database, you should import the SQL from
tables-generated-globalblocks.sql
into the global blocking database. - You also need to run
update.php
on each of your local databases, or otherwise import the SQL schema intables-generated-global_block_whitelist.sql
to them. - Fait – Accédez à Special:Version sur votre wiki pour vérifier que l'extension a bien été installée.
Configuration
Config variable | Description | ||
---|---|---|---|
$wgApplyGlobalBlocks | Whether to respect global blocks on this wiki. This is used so that global blocks can be set on one wiki, but not actually applied there (i.e. so people can contest them on that wiki). | ||
$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 tâche 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 |
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.
|
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
The following requires appropriate permissions, assigned by default to stewards, which by default can be added or removed by bureaucrats. To make a global block:
- Go to Special:GlobalBlock.
- 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).
- 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.
- 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 Extension:AbuseFilter is installed, globally blocked IP addresses are prohibited from viewing the abuse log if the particular wiki is opted in to the block.
To remove a global block:
- Go to Special:GlobalUnblock and click "Remove a global block".
- 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.
See also
- Combating spam
- Combating vandalism
- BulkBlock Extension — an extension that allows administrators to easily block multiple users at once on a MediaWiki website.
Cette extension est utilisée par au moins un des projets Wikimédia. Cela signifie probablement que l’extension est assez stable et fonctionnelle pour être utilisée sur des sites à fort trafic. Recherchez le nom de cette extension dans le CommonSettings.php de Wikimédia et dans le fichier de configuration InitialiseSettings.php pour situer les endroits où elle est installée. Une liste complète des extensions installées sur un Wiki donné peut être visualisée sur la page Special:Version de ce wiki. |
Cette extension est incluse dans les fermes de wikis ou les hôtes suivants et / ou les paquets : Cette liste ne fait pas autorité. Certaines fermes de wikis ou hôtes et / ou paquets peuvent contenir cette extension même s'ils ne sont pas listés ici. Vérifiez toujours cela avec votre ferme de wikis ou votre hôte ou votre paquet avant de confirmer. |
Categories:
- Stable extensions/fr
- Special page extensions/fr
- User identity extensions/fr
- API extensions/fr
- Database extensions/fr
- GPL licensed extensions/fr
- Extensions in Wikimedia version control/fr
- CentralAuthInfoFields extensions/fr
- ContributionsToolLinks extensions/fr
- GetBlockErrorMessageKey extensions/fr
- GetLogTypesOnUser extensions/fr
- GetUserBlock extensions/fr
- LoadExtensionSchemaUpdates extensions/fr
- OtherBlockLogLink extensions/fr
- SpecialContributionsBeforeMainOutput extensions/fr
- SpreadAnyEditBlock extensions/fr
- UserIsBlockedGlobally extensions/fr
- UserMergeAccountFields extensions/fr
- All extensions/fr
- Extensions used on Wikimedia/fr
- Extensions included in Miraheze/fr
- Extensions included in Telepedia/fr
- Extensions included in WikiForge/fr
- Extensions for data exchange with other local wikis/fr