MyBB Community Forums

Full Version: Users load forum to find themselves logged in another account
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
The only thing that will be of any help is knowing what that PHP code returns when it's run.
This could be a CloudFare-related issue, if any of you run CloudFare on your forums. This has recently happened at a forum I'm a moderator on, and I was told it was a HTTP request issue resulting in multiple users returning the same IP address, which led to a lot of people being mistakenly banned for using suspected multiple accounts. It was apparent that the initial problem arose out of the use of CloudFare technology.

Maybe something to check out. Issues seem quite similar in nature.
(2012-05-26, 01:07 PM)UndiscoveredTalent Wrote: [ -> ]...
Maybe something to check out. Issues seem quite similar in nature.

The CloudFare issue has both a plugin and a simple fix; Not the same as this thread.
I'm almost certain this is a problem related to the sessions table but could also be something to do with http cache mechanisms too. I had these problems more often when I ran memcache than I do now with xcache.
(2012-05-26, 09:40 AM)MattRogowski Wrote: [ -> ]The only thing that will be of any help is knowing what that PHP code returns when it's run.

Alright.
Sorry for being dumb, but how can I get you that?
Thank you!
(2012-05-27, 08:43 AM)Jen_Vuongyen Wrote: [ -> ]
(2012-05-26, 09:40 AM)MattRogowski Wrote: [ -> ]The only thing that will be of any help is knowing what that PHP code returns when it's run.

Alright.
Sorry for being dumb, but how can I get you that?
Thank you!

Create a file on your server and put that code in it. Tell people that whenever they have this problem to immediately go to that page and send you what it outputs, and then you can send it to us.
A user on my forum has reported the same problem as well. She has tried different browsers and still sees the same problem: forum software "sometimes" confuses her with another user.
I pulled their session information, login key, etc. from the database and they are all different. The only thing in common is that both use the same ISP and the first two bytes (left most bytes) of their IPs are the same.
I know that a lot of ISPs have some sort of caching like Squid, etc. which might cause this problem, but I can't say if it is the ISP caching or not. I use Memcache and my forum is now on CloudFlare, but she reported the problem when the forum was not on CloudFlare. So, for sure this is NOT something caused by CloudFlare.
I fixed this problem a while ago, but forgot to update this thread. The problem is that some ISPs do aggressive caching and as a result show the contents of a page with the same URL visited by user A to user B who visits the page shortly afterwards. Unfortunately, this problem exists with MyBB 1.8 as well.

The only way I have been able to fix this issue is to modify the inc/functions.php and change send_page_headers function to send Cache-Control: private. Here is how this function looks like on my server (the else statement is added):

function send_page_headers()
{
	global $mybb;

	if($mybb->settings['nocacheheaders'] == 1)
	{
		header("Expires: Sat, 1 Jan 2000 01:00:00 GMT");
		header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
		header("Cache-Control: no-cache, must-revalidate");
		header("Pragma: no-cache");
	}
	else
	{
        header("Cache-Control: private");
        header("Pragma: private");
	}	
}
Pages: 1 2 3