Extension:Username Blacklist

The Username Blacklist extension allows wiki administrators to block the creation of user accounts where the username matches one or more regular expressions.


 * To blacklist content -- to refuse edits that include certain words or URLs -- see manual:$wgSpamRegex

Requirements
The Username Blacklist extension requires MediaWiki 1.5.8 or above.

Installation

 * 1) Check out all extension files from Subversion and place them in a UsernameBlacklist subdirectory within your MediaWiki extensions directory
 * 2) Add the line   to your LocalSettings.php file

Installation can be verified through the Special:Version page on the wiki.

Editing the blacklist
The username blacklist is maintained as a message page called "usernameblacklist", which can be found at MediaWiki:Usernameblacklist.

The page is formatted as a bulleted list using the asterisk (*) token, where each blocked username or regular expression exists as a single list item, for example:


 * Foo
 * [Bb]ar

Lines without the list token will be ignored when constructing the final regular expression, which allows for adding comments or other explanation to the page.

Customising warning messages
When an attempt to create an account is blocked due to a blacklisted username, a warning message is shown to the user. This can be customised via messages:


 * MediaWiki:Blacklistedusername : Heading
 * MediaWiki:Blacklistedusernametext : Explanation

Change log
A complete log of changes to the extension code (including internationalisation updates from third parties) is available from the Subversion log, however, summarised information on changes between point releases is given below:

Acknowledgements
The extension author would like to thank:


 * The poster on mediawiki-l who inspired creation of the extension
 * Ævar Arnfjörð Bjarmason (extension code reference)
 * Brion Vibber (UTF-8 and other bug fixes)
 * The volunteer MediaWiki internationalisation team, who provided dozens of translations

Resources on regular expressions

 * Brief Introduction to Regular Expressions
 * http://etext.lib.virginia.edu/services/helpsheets/unix/regex.html
 * The 30 Minute Regex. Tutorial
 * http://codeproject.com/dotnet/RegexTutorial.asp