Last modified: 2008-05-07 01:46:05 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 T3396, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 1396 - "Persistent" login expires many times within a single session
"Persistent" login expires many times within a single session
Status: RESOLVED WORKSFORME
Product: MediaWiki
Classification: Unclassified
User login and signup (Other open bugs)
unspecified
All All
: Normal normal with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 2590 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-01-24 07:22 UTC by SJ
Modified: 2008-05-07 01:46 UTC (History)
5 users (show)

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


Attachments
Cookie from Meta for "persistent" login (293 bytes, text/plain)
2005-04-17 04:26 UTC, Brian Jason Drake
Details

Description SJ 2005-01-24 07:22:50 UTC
Even with the "remember login across sessions" flag set on login, logging into
en or meta often has to be done 3 or 4 times a day.  It is not clear to me why
or when I get logged out; someone suggested that this may be a function of how
many hits the site is getting, and that some kind of session purging is going
on.  This does seem to happen more frequently for logins on the en: wikipedia
than on other sites.

Whatever the cause, it is frustrating; particularly in the absence of universal
login, I am often logged into 4 or 5 projects at once, doing work across
projects (for instance, checking up on translations of the article on unrest in
Belize requires working on wikinews, en:wp and other lang wps...), so having to
log in to each site multiple times can be a pain.
Comment 1 Brian Jason Drake 2005-04-17 04:20:54 UTC
I presume this is not due to you changing your password that often. 
It could be because of cookies being deleted. How reliable 
are "persistent" logins on other sites for you?
Comment 2 Brian Jason Drake 2005-04-17 04:26:56 UTC
Created attachment 424 [details]
Cookie from Meta for "persistent" login

I closed the browser, deleted the cookie, logged in again using the
"persistent" login checkbox and copied the cookie immediately.
Comment 3 Brian Jason Drake 2005-04-17 04:27:48 UTC
You remain logged in until you close the browser, even if you delete 
the cookie.
Comment 4 Tempshill 2005-06-30 23:47:04 UTC
I may have a workaround for this user.

I was unable to keep logged in for more than a few seconds today using Firefox
1.0.4.  I noticed that my enWikiUserID and enWikiUserName cookies were both set
to expire right away, as soon as I logged in.  My enwiki_session cookie was set
to expire when the browser is closed, as you'd expect.

I removed the 3 cookies mentioned above, logged in again, and it seems to be
working fine now.  I had not noticed these problems using IE, only using Firefox.

Perhaps this user could try deleting the three en.wikipedia.org cookies and
logging in again?
Comment 5 Tobias Hahn 2005-11-03 16:20:52 UTC
i am having this problem, too. no problems with persistent logins on other
sites, and until today, i was able to use wikipedia without this bug.

bug 2590 is probably a dup.
Comment 6 Tobias Hahn 2005-11-03 16:24:30 UTC
changed severity to blocker since i cannot reasonably perform any edits any
longer. after a few seconds at most, i get logged out. sometimes i cannot even
edit my own preference pages right after login.
Comment 7 Tobias Hahn 2005-11-03 16:32:27 UTC
also experiencing bug 2237, i.e. when i go back in the browser and try to edit a
page, wikipedia sometimes does recognize my login and sometimes tells me i need
to login.

seems related.
Comment 8 Tobias Hahn 2005-11-03 16:40:45 UTC
i am also experiencing bug 2237, i.e. when i go back in the browser and try to
edit a page, wikipedia sometimes does recognize my login and sometimes tells me
i need to login. this is especially annoying when it recognizes my login when
clicking on edit and then tells me that i have to login to add something to my
watchpage when commiting the edit.

seems related.

changed "OS" to "All" since I and the reporter of bug 2590 are on mac.
Comment 9 Super-Magician 2005-11-04 22:32:22 UTC
*** Bug 2590 has been marked as a duplicate of this bug. ***
Comment 10 Jeff Fritz 2006-01-16 15:20:15 UTC
(In reply to comment #8)
> i am also experiencing bug 2237, i.e. when i go back in the browser and try to
> edit a page, wikipedia sometimes does recognize my login and sometimes tells me
> i need to login. this is especially annoying when it recognizes my login when
> clicking on edit and then tells me that i have to login to add something to my
> watchpage when commiting the edit.
> 
> seems related.
> 
> changed "OS" to "All" since I and the reporter of bug 2590 are on mac.

I also experience the same exact problem comment #8 has.  In addition, when
trying to login under Firefox, it logs me in, but tells me that I am blocking
cookies and need to enable them in order to login.

Without any action I stay logged in for that session and can edit pages and make
changes.  An examination of the cookies shows that Cookies are actually set, and
set to expire on "Wednesday, February 15, 2006 10:11:51 AM" -- even though the
time in which I logged in is "Monday, February 16, 2006 10:11:51 AM".

Upon closing and re-opening of the wiki site, it says I am logged in for the
first pageview or two, then when I try to do any action it tells me I have to
log in.

Comment 11 Ilya Schurov 2006-04-02 18:45:17 UTC
Experiencing the bug like this on my own mediawiki-driven site. 'Persistent'
logins doesn't work at all -- no login data saved between sessions, however all
cookies are set up. At the same time Wikipedia's persistent login works well. --
Ilya Schurov.
Comment 12 Vince Buffalo 2006-08-08 19:29:43 UTC
I took am experiencing this bug. Even when I reset safari entirely, and try to edit a page, it prompts me for my login. I am on OS X 
too, so it seems to be a mac problem. It does not work with Camino either.
Vince Buffalo
Comment 13 cannedfood_TA 2006-08-08 20:21:35 UTC
(In reply to comment #3)
> You remain logged in until you close the browser [?window], even if 
you delete the cookie.

That's because of caching, no doubt.
Comment 14 Vince Buffalo 2006-08-08 20:25:54 UTC
I've found that if I use a proxy (in this case, my university's) it completely fixes the problem. However, this is inconvenient due to 
the lag but it may offer some sort of insight into what's going on. 
Vince Buffalo
Comment 15 Vince Buffalo 2006-08-08 21:46:25 UTC
Working with the extremely helpful people on #mediawiki, I've learned that this problem is probably due to timezone settings. 
Initially I used php v. 5.1.2 which I guess requires timezones to be set. My web host did not do this, so the session cookies would 
be set incorrectly. When I jumped down to php version 5.0 which has different date and time properties it worked fine. So I guess 
either set date.timezone or use php 5.0
Comment 16 P Bere 2007-10-16 23:40:46 UTC
I experiencing the same bug, I can't stay logged on, as soon as I click any link I loose my login. I have php 5.1.2 installed. I am using Windows 2003 - IIS server and MySQL database.

I have tried setting the date.timezone in the php.ini using the command Localtimezone= Australia/Melbourne. I have also changed in my LocalSettings.php as follows:
$wgLocaltimezone="Australia/Melbourne";
   putenv("TZ=$wgLocaltimezone");
   $wgLocalTZoffset = date("Z") / 60;

This has not resolved my problem. Please help - I am not really keen on installing php version 5.0. 
Comment 17 P Bere 2007-10-17 22:59:00 UTC
(In reply to comment #15)
> Working with the extremely helpful people on #mediawiki, I've learned that this
> problem is probably due to timezone settings. 
> Initially I used php v. 5.1.2 which I guess requires timezones to be set. My
> web host did not do this, so the session cookies would 
> be set incorrectly. When I jumped down to php version 5.0 which has different
> date and time properties it worked fine. So I guess 
> either set date.timezone or use php 5.0

Where do I change the date.timezone and what is the syntax?
Comment 18 Brion Vibber 2007-10-18 14:26:54 UTC
Timezones affect only display of timestamps in the user interface and should not have any relation whatsoever to this.
Comment 19 J. Andrew Poth 2008-02-21 16:24:47 UTC
Maintaining a persistent login has become a hit-or-miss proposition for me.  I've managed to get the system to "remember me" between SeaMonkey browser sessions for en.wikipedia, de.wikipedia, commons.wikimedia and en.wikiquote, but the mechanism appears to be COMPLETELY BROKEN for en.wiktionary now.  I've done all the usual things -- cleared the cache, cleared the cookie file (even manually deleted cookies.txt), but nothing seems to fix it.

Moreover, testing my login with Microsoft Internet Explorer 6 today, it appears it can't maintain a login even for ten seconds at en.wikipedia!  As soon as I click on the Log In button and then click the Return to Main Page link, it shows "Log In / Create Account" at the upper left part of the screen.  The browser is, in fact, still logged in, but the display on the Main Page is lying.  To access one's talk, preferences, watch and contribution page links, one needs to manually navigate away from the Main Page by, say, clicking on the Random Article link at the left side of the screen.  If I shut down Internet Explorer and restart it, at the Main Page it displays "Log In / Create Account", but clicking on the Random Page link reveals that the persistent login cookie is working.  For some reason the Main Page is lying to Internet Explorer.

After running these tests with IE6, I returned to the problem of en.wiktionary not maintaining the persistent login cookie in SeaMonkey.  It turns out that the cookie IS working, except the Main Page is lying, just as it does with IE6 and en.wikipedia.  By clicking on the Random page link, it shows that I'm still logged in.
Comment 20 J. Andrew Poth 2008-02-21 16:29:38 UTC
(In reply to comment #19)
> As soon as I click on the Log In button and then click the Return to Main 
> Page link, it shows "Log In / Create Account" at the upper left part of the 
> screen.

I meant to say "upper right" part of the screen.

Comment 21 Brion Vibber 2008-02-23 00:56:00 UTC
That's a recent caching-related issue, which should be worked around now or soon.
Comment 22 Ben Bucksch 2008-03-04 04:57:47 UTC
> As soon as I click on the Log In button and then click the Return
> to Main Page link, it shows "Log In / Create Account" at the
> upper left part of the screen.  The browser is, in fact, still
> logged in, but the display on the Main Page is lying.

The browser is caching the main page.
This is independent from the bug here.
Comment 23 Brion Vibber 2008-05-07 01:46:05 UTC
The history of this bug seems to conflate several separate issues over the course of a couple years...

A couple quick notes:

* The token cookie for the "remember this login" checkbox is reset each time you do it. This means you can only have your persistent session open for one browser at a time for each site -- doing it on another browser will invalidate the token the first browser had saved.

* The IIS server noted above sounds like a typical issue with PHP session data not being kept on the server due to misconfiguration.

* There was a caching issue breaking some cookies specifically a couple months ago.

I'm going to go ahead and close this bug as a WORKSFORME on assumption that the really old problems got resolved one way or another; if it does still happen, we can't hope to investigate without being able to interact directly with somebody encountering it.

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


Navigation
Links