Extension:AccessControl/fr

L'extension AccessControl permet de restreindre l'accès à des pages spécifiques en fonction de groupes internes ou de listes de groupes depuis l'espace utilisateur. MediaWiki dans son état par défaut n'est pas conçu comme un système de gestion de contenu (CMS), mais lorsqu'il est utilisé comme intranet d'entreprise ou scolaire, cela est nécessaire pour protéger les données sensibles. AccessControl a été développé à cet effet. AccessControl has been developed for this purpose. 

Comment cette extension répond aux exigences de sécurité du site

 * Atom/RSS feeds, diff, & revision links : Page content is protected, but when opening a page from history a piece of raw content will appear. If the  tag was placed at the beginning, a potential attacker may be able to see the names of contributing users!


 * Listings & search : Unless otherwise noted, if there is any page with protected content in search results, the user is redirected away. Since extension version 2.5, searching may be allowed too. But it should be borne in mind that the displayed search results can compromise sensitive data. Therefore, do not write in your wiki sensitive information, such as passwords, that could be obtained through a fulltext search if searching through the contents of pages protected through an access control is allowed!


 * Inclusion/transclusion, related rights, & other extensions : Pages containing the  tag, or including another page protected by the   tag, are secure. The   tag is processed in raw wikitext before HTML conversion.


 * Redirects : The problem with redirection was repaired in version 1.1


 * API & action links : For each anonymous user the action class is automatically set to, besides the view attribute for unprotected pages. Allowed actions for authorized users depend on the permissions settings of MediaWiki and the username listed in the access list pages use.


 * Edit Section & watching pages : Options are available only to registered users if they are logged in and are on the security access list.


 * Fichiers et images :


 * Export XML ( Special:Export )
 * {{warning|1= AccessControl version < 2.0, was based on a hook unprotected from MediaWiki's side before exporting pages to raw code. Therefore, if you use AccessControl version < 2.0, you must prohibit the special page to prohibit exporting the pages from MediaWiki.


 * Author backdoor : Extension AccessControl does not have a backdoor!
 * Caching : Is recommend turning off caching. See the previous paragraphs.

Plus d'informations sur les problèmes potentiels concernant la sécurité sont sur la page Security issues with authorization extensions.

Fonctionnalités
See how this extension meets the requirements for site security.
 * Facile à installer et simple à utiliser.
 * Pas de correctifs pour le cœur de MediaWiki.
 * Groupes illimités.
 * Contrôle d'accès en mode double :
 * Afficher le contrôle.
 * Modifier le contrôle, y compris les restrictions sur l'accès à la modification manuelle lors de l'utilisation de action=edit dans l'URL.
 * Les groupes d'utilisateurs peuvent utiliser n'importe quel espace de noms.
 * Les espaces de noms avec des listes de groupes peuvent être protégés par une autre extension.
 * Le groupe d'administrateurs MediaWiki peut afficher et modifier les pages protégées.
 * Contrôlé par la variable d'extension
 * L'accès peut être accordé à plusieurs groupes
 * L'accès en lecture seule peut être accordé aux groupes et aux utilisateurs individuels.
 * Les utilisateurs non autorisés peuvent utiliser la fonction de recherche uniquement si cela est autorisé. Voir comment cette extension répond aux exigences de sécurité du site.

Documentation
Manual (in Czech language for now) here as wiki page, but is prepared for translation. If you want to contribute to creating an English version, you must donate any amount of money to pay for a commercial translator, because the author does not have the time and skills for it. The man page (for now only Czech version) is part of the source code, and can be imported into your private MediaWiki instance if you want.

Installation


Étape 1 : Fichier de paramètres locaux

 * First check that you have set these variables in the file. If not, set them:


 * Add the following lines to the bottom of your :

Step 2: Read manual
Version 6.0 supports the old syntax of this extension. New syntax based on template parameters is very sophisticated. But for base use we can still use the AccessList created by the old syntax, and protect pages by element accesscontrol.

Using
The new version has a new access rights setting system, based on template parameterization. If the parser encounters any of the following parameters while processing a template, it will call AccessControl to check if the user has access to the content.


 * isProtectedBy - list of user groups
 * readOnlyAllowedGroups - user groups with read-only access
 * editAllowedGroups - user groups with edit access
 * readOnlyAllowedUsers - list of users who can only read the content of the site
 * editAllowedUsers - a list of users with editing rights

Within a single template, all of the above parameters can be used at the same time, so the indentation indicates their hierarchical position in terms of rights. You will learn more in the description of each parameter, where examples will also be given.

editAllowedUsers
Using this parameter turns a regular template into a list of users. Each user whose name is specified in this parameter will have the right to edit the page into which the template with this parameter will be inserted. And also all pages that use it in the  parameter. If more than one user is specified, their usernames are separated by a comma.

Simple example self-protected page (i.e. ) where is in code used  :

I can be used to protection another page, if wikitext content use any template with the parameter, where is as value name the self-protected page. See example:

It can be (not must!) edited by Page Form.

Using of the old syntax
First create User Groups. It may be any page stored in the main namespace, only colon must be after first word in the name. User lists can be a page in the namespace titled "Department" Each username appears as a list item.


 * User names listed with  at the end can only read the protected article, not edit it. For other groups of users, you can create another member list, i.e. ,   & etc. Note that old syntax has problem with the user's name with whitespaces!


 * Example tag code

Configuration
Check the settings in  file. These can be set in LocalSettings.php:


 * Depending on localization, your wiki needs pages created to which anonymous or unauthorized users will be redirected. You have to create them in advance because some of them can't access pages from another page.


 * The safety of the page is provided by the  tag. If there isn't a tag or the page is empty, it's freely accessible to logged-in users that can read and edit the page. No user, logged in or anonymous, will have read-only access.


 * Members from groups listed in the  tag can edit the page only if the group title isn't listed with   and if they don't have read only access set in the group member list.


 * By default the variable is set to true so that members of sysop can edit user group pages in any namespace.

For version < 4.1
If for some reason you cannot upgrade your MediaWiki to version 1.39 LTS, you can continue to use version 4.1 of the form-support branch. If you have a problem with the update, because any problem occured and blocked your actualization, write in the discussion. MediaWiki is very complexity software, and sometime a little bug may be as big problem for admins without the programming experiences.

If your Mediawiki Version ≥ 2.6 isn't recommend for use, because have not support of the maintainer.

Il est fortement recommandé d'utiliser la version 2.5.1.



Pour les versions < 2.3

 * Il y avait un problème dans la fonction fromTemplate qui faisait qu'AccessControl ignorait les balises des pages ou des modèles inclus. L'actualisation est recommandée !



Pour les versions ≥ 2.0
This means that a page that has an ACL will trigger an "Access Denied" message for end users who happen to search for text contained in a protected page. A simple solution is to put pages that require AccessControl into another namespace and then disable searching for that namespace. Although this isn't really a bug, it is undesirable behavior. Click here for an example showing a work around.
 * Les pages ne peuvent avoir qu'un seul élément &lt;accesscontrol>.
 * Si l'utilisateur est membre de plusieurs groupes, le groupe qui lui donne le plus d'accès est supposé.
 * This extension uses a MediaWiki hook that is called whenever a search result is displayed.



Pour les versions ≤ 1.3

 * Les groupes de MediaWiki ne doivent pas être sous forme localisée ! sysop ne peut pas être Správce, etc.
 * Une page peut contenir plusieurs éléments &lt;accesscontrol>, l'accès étant accepté à partir de groupes dans n'importe quelle balise.
 * Les utilisateurs anonymes n'ont pas accès aux pages protégées par les éléments &lt;accesscontrol>.
 * Si la variable  est vraie, les sysops ont toujours un accès en modification.



Test de Version MediaWiki

 * La version 4.1 de la branche  du dépôt git (voir le lien pour cloner en haut de cette page) a été testée sur MediaWiki 1.35 la version stable actuelle de support à long terme (septembre 2023) This version is recomend for use on  MediaWiki 1.29< 1.35

Historique
La première version de cette extension (1.x) était basée sur, mais sans les bogues de l'original.


 * La version 4.0 est obsolète (T281848). Mise à niveau recommandée.
 * La version 3.0.1 a été testée sur MediaWiki 1.34.0, mais est obsolète. Mise à niveau recommandée.
 * La version 2.5.1 a été testée sur MediaWiki 1.33.0-alpha (5eb97ec)
 * La version 2.6 a été testée sur MediaWiki 1.27.0-rc.0 (57f722a)
 * La version 2.5 a été testée sur MediaWiki 1.27.0 (depuis le dépôt git)
 * Version 2.5 was tested on MediaWiki 1.22.9 (from git repository)
 * Version 2.3 was tested on MediaWiki 1.22.0 (from git repository)
 * Version 2.2 was tested on MediaWiki 1.22.0 (from git repository)
 * Version 2.0 was tested on MediaWiki 1.19-alpha (from svn repository)
 * Version 1.2 was tested on MediaWiki 1.15.5-1 (from Debian repository)
 * Version 1.1 was tested on MediaWiki 1.16.0(b3). Works fine, except that it needed a minor change to line 358 of AccessControl.php (remove '&' from parameter to  ). When viewing a page on a Linux server, the  tags show. But on a Windows server, the tags don't show and it is fine! Still haven't figured that one out, but it is ok for my application.
 * Version 1.1 was tested on MediaWiki 1.15
 * Version 1.0 of this extension has been tested and works fine on MediaWikis > 1.12.x.
 * Version 1.1 tested on MediaWiki 1.16.1 with new patch from http://git.felk.cvut.cz/pub/git?p=accesscontrol.git;a=commitdiff;h=2f678deed0e4e4f77620e391c94559c7b50102a9



Voir aussi

 * Extension:Semantic ACL
 * Extension:Semantic ACL