X-Git-Url: https://git.toastfreeware.priv.at/toast/cookiecaptcha.git/blobdiff_plain/c112c24f54cce653e9089fdaff2bf7e691a8a248..73cfd41936d8d494b502dbd51ab5a864a9445c80:/ConfirmEdit.php diff --git a/ConfirmEdit.php b/ConfirmEdit.php index 2faac7f..7a4f78a 100644 --- a/ConfirmEdit.php +++ b/ConfirmEdit.php @@ -35,6 +35,7 @@ global $wgExtensionFunctions, $wgGroupPermissions; $wgExtensionFunctions[] = 'confirmEditSetup'; $wgExtensionCredits['other'][] = array( + 'path' => __FILE__, 'name' => 'ConfirmEdit', 'author' => 'Brion Vibber', 'url' => 'http://www.mediawiki.org/wiki/Extension:ConfirmEdit', @@ -55,6 +56,7 @@ $wgGroupPermissions['user' ]['skipcaptcha'] = false; $wgGroupPermissions['autoconfirmed']['skipcaptcha'] = false; $wgGroupPermissions['bot' ]['skipcaptcha'] = true; // registered bots $wgGroupPermissions['sysop' ]['skipcaptcha'] = true; +$wgAvailableRights[] = 'skipcaptcha'; /** * List of IP ranges to allow to skip the captcha, similar to the group setting: @@ -146,6 +148,13 @@ $wgCaptchaBadLoginExpiration = 5 * 60; global $ceAllowConfirmedEmail; $ceAllowConfirmedEmail = false; +/** + * Number of bad login attempts before triggering the captcha. 0 means the + * captcha is presented on the first login. + */ +global $wgCaptchaBadLoginAttempts; +$wgCaptchaBadLoginAttempts = 3; + /** * Regex to whitelist URLs to known-good sites... * For instance: @@ -170,6 +179,7 @@ $wgSpecialPages['Captcha'] = array( /*class*/'CaptchaSpecialPage', /*name*/'Capt $wgConfirmEditIP = dirname( __FILE__ ); $wgExtensionMessagesFiles['ConfirmEdit'] = "$wgConfirmEditIP/ConfirmEdit.i18n.php"; +$wgExtensionAliasesFiles['ConfirmEdit'] = "$wgConfirmEditIP/ConfirmEdit.alias.php"; if ( defined( 'MW_SUPPORTS_EDITFILTERMERGED' ) ) { $wgHooks['EditFilterMerged'][] = 'ConfirmEditHooks::confirmEditMerged';