When using AuthPlugin and entering an existing username with a wrong password,
MediaWiki responds with an error message stating that the given username does
not exist. This is incorrect and confusing.
Patch to fix it:
- SpecialUserlogin.php.orig Wed Mar 2 12:38:07 2005
+++ SpecialUserlogin.php Wed Mar 2 12:42:50 2005
@@ -248,10 +248,14 @@
- automatically create a new account for users that
- are externally defined but have not yet logged in. */
- if( $wgAuth->autoCreate() &&
- $wgAuth->userExists( $u->getName() ) &&
- $wgAuth->authenticate( $u->getName(),
$this->mPassword ) ) {
- $u =& $this->initUser( $u );
+ if( $wgAuth->autoCreate() && $wgAuth->userExists(
$u->getName() ) ) {
+ if( $wgAuth->authenticate( $u->getName(),
$this->mPassword ) ) {
+ $u =& $this->initUser( $u );
+ }
+ else {
+ $this->mainLoginForm( wfMsg(
'wrongpassword' ) );
+ return;
+ }
} else { $this->mainLoginForm( wfMsg( 'nosuchuser',
$u->getName() ) );
return;
Version: 1.4.x
Severity: minor