Reset password throttles on login
authorAndrew Garrett <werdna@users.mediawiki.org>
Tue, 26 Aug 2008 22:24:44 +0000 (22:24 +0000)
committerAndrew Garrett <werdna@users.mediawiki.org>
Tue, 26 Aug 2008 22:24:44 +0000 (22:24 +0000)
includes/specials/SpecialUserlogin.php

index 00c93d6..82a1ac9 100644 (file)
@@ -520,6 +520,11 @@ class LoginForm {
                                }
                                $wgUser->setCookies();
 
+                               // Reset the throttle
+                               $key = wfMemcKey( 'password-throttle', wfGetIP(), md5( $this->mName ) );
+                               global $wgMemc;
+                               $wgMemc->delete( $key );
+
                                if( $this->hasSessionCookie() || $this->mSkipCookieCheck ) {
                                        /* Replace the language object to provide user interface in correct
                                         * language immediately on this first page load.