Last modified: 2012-11-04 17:38:54 UTC
In User::getBlockedStatus(), proxy detection sets $this->mBlockedReason and $this->mBlockedby but doesn't set $this->mBlock, so getBlock/isBlocked don't see it. Should probably synthesize a Block object here...?
This may not be the best way to fix it, but I've found that modifying ./includes/specials/SpecialUserlogin.php to include a check for $wgUser->blockedBy() is able to get things working again. The specific problem I was running into was that $wgProxyList seems to allow banned IPs to create accounts, but prevents them from editing. By setting up a bannedips.php file as specified on http://www.mediawiki.org/wiki/Manual:Combating_spam, I was able to prevent spam edits, but my Recent Changes were becoming bloated with a lot of bogus accounts. Old: if ( !$wgUser->isAllowed( 'createaccount' ) ) { $wgOut->permissionRequired( 'createaccount' ); return false; } elseif ( $wgUser->isBlockedFromCreateAccount() ) { $this->userBlockedMessage(); return false; } New: if ( $wgUser->blockedBy()){ $this->userBlockedMessage(); return false; } elseif ( !$wgUser->isAllowed( 'createaccount' ) ) { $wgOut->permissionRequired( 'createaccount' ); return false; } elseif ( $wgUser->isBlockedFromCreateAccount() ) { $this->userBlockedMessage(); return false; }
This was fixed in bug 35303 / https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/core.git;a=commitdiff;h=eb5e031f310ddd8ba871219dd7fa939a904ea638 *** This bug has been marked as a duplicate of bug 35303 ***