Last modified: 2012-12-24 06:26:53 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T34363, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 32363 - Login sometimes causes unexpected "Login Error" message
Login sometimes causes unexpected "Login Error" message
Status: NEW
Product: MediaWiki
Classification: Unclassified
User login and signup (Other open bugs)
1.16.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-11-11 18:42 UTC by Dan Nessett
Modified: 2012-12-24 06:26 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Dan Nessett 2011-11-11 18:42:08 UTC
This bug was discovered while working on bug 32122 (https://bugzilla.wikimedia.org/show_bug.cgi?id=32122). In order to reproduce it reliably, a developer must make the following changes to php.ini (this should *not* be done on a production machine, since the settings force the PHP garbage collector to run on every page access).

- session.gc_probability = 100
- session.gc_divisor     = 100
- session.gc_maxlifetime = 60
- session.save_path = <some directory writable by httpd>

After making these changes restart httpd. Then execute the following:

Login

Immediately log out

Wait more than 60 seconds. Do not change the page, stay on the "Log out" page
which states: "You are now logged out. You can continue to use MW_1_16_5
anonymously ..."

Login

The error:

"Login error
 There seems to be a problem with your login session; this action has been
canceled as a precaution against session hijacking. Go back to the previous
page, reload that page and then try again."

is displayed.

This bug appears to arise due to session management logic in MW in tandem with PHP session garbage collection. One commenter on bug 32122 suggests this is expected behavior. However, from a user's point of view that is highly unlikely.

One possible solution is to destroy the session on logout. There is a PHP function, session_destroy that destroys session data, but it isn't clear whether that function actually deletes the session file. Also, it isn't clear how to delete sessions held by memcached.
Comment 1 Dan Nessett 2011-11-11 19:40:42 UTC
I should have stipulated that when logging in DO NOT CHECK THE "REMEMBER ME" BOX.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links