Manual talk:$wgAccountCreationThrottle

Allowed Values:
Why is it not possible to limit the number to less than 10? One would be nice if your site is being spammed.Dejvid 22:34, 13 August 2007 (UTC)
 * I guess this was an old limitation, since it works fine with 1 now. --Kipcool (talk) 23:24, 14 June 2013 (UTC)

Why memcached
Why is memcached required? For smaller wikis memcached seems not necessary but they are spammed as well.


 * From what I saw, memcached is required because you need to log the number of login per ip per day, but ip information is not stored in a normal Mediawiki installation. So they use memcached to store a counter for each ip (the value of the counter is stored 1 day, then deleted).
 * I changed the following to have $wgAccountCreationThrottle work also if you are using APC cache instead of Memcached:
 * modify the file
 * After the line with  replace the code that follows with this:

if ( $wgMainCacheType == CACHE_MEMCACHED ) { $cacheManager = $wgMemc; } elseif ( $wgMainCacheType == CACHE_ACCEL ) { $cacheManager = new APCBagOStuff; }

if ( isset( $cacheManager )) { $value = $cacheManager->get( $key ); if ( !$value ) { $cacheManager->set( $key, 0, 86400 ); }	if ( $value >= $wgAccountCreationThrottle ) { return Status::newFatal( 'acct_creation_throttle_hit', $wgAccountCreationThrottle ); }	$cacheManager->incr( $key ); }
 * I hope it works fine :) Should I submit a patch? --Kipcool (talk) 23:22, 14 June 2013 (UTC)