[Mediawiki-l] User Groups

Brion Vibber brion at pobox.com
Wed Jun 30 02:01:32 UTC 2004


Joachim Durchholz wrote:
> My idea was to have "user groups" in the wiki, and a per-page list of 
> groups that may read or write it.
> 
> The docs were of limited help. A remark somewhere in them reads "it's 
> possible to do your own permission scheme", but I found nothing that 
> supported that claim. In fact all the permission stuff that's in 
> Mediawiki seems to be hardcoded, at least a few quick greps indicated so.

You can theoretically build a users/groups permissions scheme using the 
user_rights and cur_restrictions fields (both are comma-separated sets 
of text tokens and can be fairly arbitrarily extended), but as you 
noticed this isn't supported by the current code which is hard-coded and 
special-cased for a few values.

If you want to try this, start by rewriting Title::userCanEdit() and 
Title::userCanRead(), which control write and read access to given 
pages. You'd also need to add a more intelligent way to assign page 
permissions & user privileges.

> My questions are:
> How do I go ahead?
> Are there better ways to achieve what we want?

Honestly, I'd recommend you just give all your users read/write 
permission to all pages... If they change things they're not supposed to 
it's recorded in the audit trail and incorrect changes can be easily 
reverted.

-- brion vibber (brion @ pobox.com)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 253 bytes
Desc: OpenPGP digital signature
Url : http://lists.wikimedia.org/pipermail/mediawiki-l/attachments/20040629/88c27298/attachment.pgp 


More information about the MediaWiki-l mailing list