Page MenuHomePhabricator

Exception from line 788 of /srv/mediawiki/php-1.27.0-wmf.4/includes/specials/SpecialUserlogin.php: Invalid status code returned from AbortLogin hook: 5
Closed, ResolvedPublic

Description

I was trying to login on mobile and temporarily forgot my password, so triggered captcha. I then tried to login on non-mobile and have the captcha there. I then click login (didn't fill out the captcha yet)

I then get an exception:

/w/index.php?title=Special:UserLogin&action=submitlogin&type=login&returnto=Q22   Exception from line 788 of /srv/mediawiki/php-1.27.0-wmf.4/includes/specials/SpecialUserlogin.php: Invalid status code returned from AbortLogin hook: 5 {"exception_id":"62466231"} 
[Exception Exception] (/srv/mediawiki/php-1.27.0-wmf.4/includes/specials/SpecialUserlogin.php:788) Invalid status code returned from AbortLogin hook: 5
  #0 /srv/mediawiki/php-1.27.0-wmf.4/includes/specials/SpecialUserlogin.php(968): LoginForm->authenticateUserData()
  #1 /srv/mediawiki/php-1.27.0-wmf.4/includes/specials/SpecialUserlogin.php(345): LoginForm->processLogin()
  #2 /srv/mediawiki/php-1.27.0-wmf.4/includes/specialpage/SpecialPage.php(384): LoginForm->execute(NULL)
  #3 /srv/mediawiki/php-1.27.0-wmf.4/includes/specialpage/SpecialPageFactory.php(553): SpecialPage->run(NULL)
  #4 /srv/mediawiki/php-1.27.0-wmf.4/includes/MediaWiki.php(248): SpecialPageFactory::executePath(Title, RequestContext)
  #5 /srv/mediawiki/php-1.27.0-wmf.4/includes/MediaWiki.php(669): MediaWiki->performRequest()
  #6 /srv/mediawiki/php-1.27.0-wmf.4/includes/MediaWiki.php(474): MediaWiki->main()
  #7 /srv/mediawiki/php-1.27.0-wmf.4/index.php(41): MediaWiki->run()
  #8 /srv/mediawiki/w/index.php(3): include(string)

Event Timeline

aude created this task.Oct 29 2015, 9:47 AM
aude updated the task description. (Show Details)
aude raised the priority of this task from to High.
aude added a subscriber: aude.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 29 2015, 9:47 AM
aude updated the task description. (Show Details)Oct 29 2015, 9:47 AM
aude set Security to None.
Tgr added a comment.Oct 29 2015, 11:41 PM

That mostly just replaces the exception on line 1088.

Tgr added a comment.Oct 29 2015, 11:53 PM
tgr@terbium:~$ mwscript eval.php --wiki=ptwikivoyage
> var_dump($wgHooks['AbortLogin']);
array(2) {
  [0]=>
  string(34) "ConfirmEditHooks::confirmUserLogin"
  [1]=>
  string(30) "CentralAuthHooks::onAbortLogin"
}

Those both look fine though.

Tgr added a comment.Oct 30 2015, 12:08 AM

Eh, that's dumb :( Should have been an array key check, not an array value check.

Change 249936 had a related patch set uploaded (by Gergő Tisza):
Fix AbortLogin hook return value check

https://gerrit.wikimedia.org/r/249936

Change 249937 had a related patch set uploaded (by Gergő Tisza):
Fix AbortLogin hook return value check

https://gerrit.wikimedia.org/r/249937

Change 249936 merged by jenkins-bot:
Fix AbortLogin hook return value check

https://gerrit.wikimedia.org/r/249936

Change 249937 merged by jenkins-bot:
Fix AbortLogin hook return value check

https://gerrit.wikimedia.org/r/249937

Tgr closed this task as Resolved.Oct 30 2015, 12:50 AM
Tgr claimed this task.

Fixed, deployed.