ElkArte Community

Project Support => Support => Topic started by: Auctor Lucan on November 07, 2018, 02:28:47 pm

Title: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 02:28:47 pm
Help!

Me and all the members are getting the Session Verification Error all of a sudden, and I can't log out from any of my devices.

Please help? Thanks in advance!
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 02:41:29 pm
We are getting session timed out notifications when we try to post.
Title: Re: Session Verification Error!
Post by: radu81 on November 07, 2018, 02:45:05 pm
Did you recently changed the cookie settings of your forum? I've had and I still have a similar problem, in my case is enough to clear the browser cookies and everything works fine. 
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 02:50:11 pm
Nope, I did not change the cookie settings. However, it seems my provider upgraded to PHP 7.2, whereas I was running on a 5.6 PHP for the forum and the wiki. I could change it back, and I did, but it still had the same problem.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 03:26:19 pm
Okay, I could actually restore the site to PHP 5.6 now, so I have until the month ends to update the forum so that it can handle PHP 7.2. Any chance you guys can help me fins a step-by-step to update my Elkarte forum to a version that can handle PHP 7.2?
Title: Re: Session Verification Error!
Post by: tino on November 07, 2018, 03:31:44 pm
Are there any errors in the logs?
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 03:39:19 pm
This is what I find there:
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 03:40:41 pm
There are also these:

 /customers/6/a/e/uss-theurgy.com/httpd.www/forum/sources/Security.php

/customers/6/a/e/uss-theurgy.com/httpd.www/forum/sources/Session.php
Title: Re: Session Verification Error!
Post by: tino on November 07, 2018, 03:43:50 pm
I think you are going to have to upgrade to Elkarte 1.1.5, I think it's easier to upgrade to 1.1.0 then to patch to 1.1.5.

If you do this, make sure you have a backup of the forum database and the forum as well.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 03:45:27 pm
Thanks! Links?

Thanks in advance!
Title: Re: Session Verification Error!
Post by: tino on November 07, 2018, 03:47:20 pm
The Releases are available here; https://github.com/elkarte/Elkarte/releases

I don't know what mods you have but some of them might not work. Ultimate menu I know requires some manual changes, which are in the support thread on here.
Title: Re: Session Verification Error!
Post by: tino on November 07, 2018, 03:49:12 pm
Also see this post

https://www.elkarte.net/community/index.php?topic=4712.msg34075#msg34075

from emanuele
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 07, 2018, 03:50:36 pm
Excellent! Thanks! If you have foreknowledge about my installed mods, here is the list. Please let me know if there is stuff that I have to delete or fix?



Title: Re: Session Verification Error!
Post by: tino on November 07, 2018, 03:52:51 pm
I think most of those have been updated, I'm not so sure about your theme though so that might need to be done as well. If you can just upgrade to 7.1 then 1.0.10 should work on that.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 05:08:01 am
I will post here after trying to remove the https stuff in htcaccess and switch to a higher PHP setting.
Title: Re: Session Verification Error!
Post by: Jorin on November 26, 2018, 06:55:23 am
I have my server forced to use https with Elk1.1.5 and PHP7.2 and I have no problems with it. So this combination should work by default.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 09:12:14 am
Yeah, that wasn't the problem. I am still getting a Session Verification Error when running my ElkArte 1.0.9 installation on PHP 7.1.

Anyone else have any ideas on what is causing this? If this can be solved, I may not have to upgrade to 1.1 Elkarte since the upgrade tool is giving me trouble.

Best,

Auctor Lucan
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 09:23:10 am
Quote from: ahrasis – 1.0 does work with php 7.2 though minor fix may be required to remove all create_function errors. I am not sure if there are errors other than that.

Is there a link to this fix that I want to try out?

Moreover, there is the Sessions error in the log (attached):
Title: Re: Session Verification Error!
Post by: radu81 on November 26, 2018, 09:40:12 am
The solution is to clear cookies on your browser. Try in incognito mode. I had the same problem 
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 09:42:58 am
Doesn't that happen when you hit Shift+F5?
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 09:59:25 am
I deleted these cookies, same result.
Title: Re: Session Verification Error!
Post by: ahrasis on November 26, 2018, 10:51:11 am
Quote from: Auctor Lucan – Is there a link to this fix that I want to try out?
For EA 1.0.x or EA 1.1.x?
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 10:55:19 am
ElkArte 1.0.9. Thanks in advance! :)
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 11:14:35 am
As for the sessions login error... maybe there is any addon linked to session (keep always log-in or whatever that modify the standard login of the forum) that could mess up with the cookies in-between PHP 5.6 and 7.X?? Like an addon that is no compatible but linked directly with the log in/cookie management?

Just brainstorming here! :)

I have a attached my installed packages, in hopes any of them may be such a culprit.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 11:20:47 am
I tried Incognito Mode, and it still doesn't allow Login/Logout.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 12:12:00 pm
Could this be it?

https://www.simplemachines.org/community/index.php?topic=542746.0

Edit: In that case, where do I find this value? (on the phone atm)
Title: Re: Session Verification Error!
Post by: radu81 on November 26, 2018, 01:04:02 pm
could be here?!? ACP -> Server settings -> Cookies and sessions
Title: Re: Session Verification Error!
Post by: tino on November 26, 2018, 04:02:43 pm
I think it would be in the php.ini
Title: Re: Session Verification Error!
Post by: vbgamer45 on November 26, 2018, 05:59:13 pm
Try that also try disabling database sessions sometimes that helps.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 26, 2018, 06:13:10 pm
Been looking and I can't find the value still. Anyone else having luck finding where to change it to false?

As for database sessions, which file and value is that?

Thanks again! :)
Title: Re: Session Verification Error!
Post by: vbgamer45 on November 26, 2018, 08:41:08 pm
admin -> server settings -> cookies and sessions -> "Use database driven sessions"


And it should be on that page for cookies secure
Title: Re: Session Verification Error!
Post by: Spuds on November 26, 2018, 08:43:33 pm
I got ninja'ed, but posting anyway :D

Is this happening for everyone or just some users?

The Cookie settings are under Admin -> Server Settings -> Cookies and Sessions

What do you have in those settings?   As VB said, you can try to turn off DB driven sessions just and see if that fixes things.  After a "bit" you should be able to re-enable that if wanted (but I'd clear the sessions table first)

As others have said, 1.0.x works fine on 7.1 or 7.2 ... I run sites like that w/o any issues, so the problem is something simple, finding it can be the hard part !
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 27, 2018, 02:08:15 am
Attaching my settings in full. Disabling cookies and database sessions did not work, but having done so, I could log in using incognito mode. Hope these images attached may render new ideas.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 27, 2018, 02:30:09 am
Quote from: Spuds – Is this happening for everyone or just some users?

Every user.
Title: Re: Session Verification Error!
Post by: ahrasis on November 27, 2018, 02:48:05 am
1.0.9 is not the latest, try to patch it with 1.0.10 if you intend to use that 1.0 branch, which is no longer supported.

Anyway, I did post somewhere in this forum a fix for php7.2.

However, a smarter move will be to move on to 1.1 branch, 1.1.5 to be exact.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 27, 2018, 03:06:46 am
I know, I have tried to patch the forum and there is some strange problem with the upgrade tool that just makes it freeze.
Title: Re: Session Verification Error!
Post by: vbgamer45 on November 27, 2018, 10:09:20 am
I wonder if now it is a cache/cookies issue. Since you said it work in incognito mode.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 28, 2018, 08:23:58 am
Eureka!

See attachment for the settings required to kill this elusive g'damn PHP 7.1 bug when using a 1.0.X version of Elkarte. Important:
1) Rename the cookie (!)
2) Use subdomain independent cookies = ON
3) Force cookies to be secure = OFF
4) Use database driven sessions = OFF
5) Lastly (!), clear the "Sessions" table in the database

Doing this made my 1.0.9 Elkarte version run on PHP 7.1, meaning that the Session Verification Error didn't appear, and my members could still use the forum. There were, however, a couple of other things that broke when switching to PHP 7.1, and I was wondering if there are present patches/fixes for these errors:

1) Mentions function, and name drop-down menus when sending Personal Messages no longer works. When we begin typing the name in the "To:" field, it doesn't generate any names any more. Does this have anything to do with the "Create" bug earlier mentioned?

2) When trying to edit Pages belonging to Simple Portal, no edit is made and you get a 500 Error white screen. I do, however, have the "1.0.0 Beta 1" version of SimplePortal installed. Can I get a link to the newest version to see if that helps?

Thanks in advance, and good riddance to have killed that g'damn elusive bug.

EDIT: Yes, I will be switching to 1.1.5 soon, when I have built a second forum as a fresh install from scratch, with the theme and the database and everything. Until then, however, I would love to get help with 1 and 2 above.

Best,

Auctor Lucan
Title: Re: Session Verification Error!
Post by: emanuele on November 28, 2018, 05:51:49 pm
Glad you solved! (At least partially.)
Sorry for disappearing, but I've been a bit sick... :-\

Can you check the error log to see if anything is in there regarding mentions and names suggestions?
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 28, 2018, 08:25:25 pm
Here is what I've found so far in that regard. See attachment.

I might be able to get more error logs later, but what about Simple Portal and the Mentions Drop-Down addons, what's the latest versions there? Has there been any fixes or patches made lately that I can try?

Thanks in advance! :)
Title: Re: Session Verification Error!
Post by: ahrasis on November 28, 2018, 10:10:37 pm
For the addons you have to refer to the respective addons page as some of them has been discussed or fixed there.

For EA 1.0.10, check my post here: https://www.elkarte.net/community/index.php?topic=4807.msg34984#msg34984

I would suggest them to be added to 1.0.11 but I think it already agreed that there'll be no 1.0.11 after 1.0.10.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on November 29, 2018, 05:42:20 am
Hi!

Quote from: ahrasis – For the addons you have to refer to the respective addons page as some of them has been discussed or fixed there.

For EA 1.0.10, check my post here: https://www.elkarte.net/community/index.php?topic=4807.msg34984#msg34984

I would suggest them to be added to 1.0.11 but I think it already agreed that there'll be no 1.0.11 after 1.0.10.

Thank you! Did you do something like this for 1.1.5 too?
Title: Re: Session Verification Error!
Post by: ahrasis on November 29, 2018, 07:13:31 am
Nope. As I mentioned there it was while I was using 1.0. 1.1.5 is already good with php7.2 so far.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on December 03, 2018, 04:11:49 am
Thanks Ahrasis!

Quote from: emanuele – Glad you solved! (At least partially.)
Sorry for disappearing, but I've been a bit sick... :-\

Can you check the error log to see if anything is in there regarding mentions and names suggestions?

I may have found the trouble with the lack of name suggestions, @emanuele , when trying to send Personal Messages and getting names for Mentions. See attachment and the mention of Line 80.

Quote            $context['xml_data'] = $suggest->$currentSearch['function']();
         }
         // Let's maintain the "namespace" action_suggest_
         elseif (function_exists('action_suggest_' . $currentSearch['function']))
         {
            $function = 'action_suggest_' . $searchTypes[$_REQUEST['suggest_type']];
            $context['xml_data'] = $function();
         }

         if (!empty($context['xml_data']))
            $context['sub_template'] = 'generic_xml';

As for the Password Hatch thing at the top, the broken off text in the top one, it says: "8192: Methods with the same name as their class will not be constructors in a future version of PHP; PasswordHash has a deprecated constructor"

Hope you guys can help me! :)
Title: Re: Session Verification Error!
Post by: Auctor Lucan on December 03, 2018, 07:02:56 am
Question, @ahrasis , regarding below:

Quote from: ahrasis – For the addons you have to refer to the respective addons page as some of them has been discussed or fixed there.

For EA 1.0.10, check my post here: https://www.elkarte.net/community/index.php?topic=4807.msg34984#msg34984

I would suggest them to be added to 1.0.11 but I think it already agreed that there'll be no 1.0.11 after 1.0.10.

I tried to do this but it didn't work out, then I saw that the code shown were from two different instances in the contents of the file. Could you please give me the lines affected or a complete file to replace my broken one? Thanks in advance!
Title: Re: Session Verification Error!
Post by: emanuele on December 04, 2018, 02:29:43 am
No other error in the log related to Suggest.controller.php?
Title: Re: Session Verification Error!
Post by: Auctor Lucan on December 04, 2018, 02:57:38 am
No, all the instances refer to line 80, and I've checked for a long duration now.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on December 04, 2018, 04:34:15 pm
Quote from: emanuele – No other error in the log related to Suggest.controller.php?

Attaching the whole file here, if it helps, @emanuele .
Title: Re: Session Verification Error!
Post by: emanuele on December 04, 2018, 04:35:23 pm
@Auctor Lucan please attach your Suggest.controller.php here.
By the look of it, that error doesn't make sense.

Never mind, too fast in clicking again post.
I'll check it.
Title: Re: Session Verification Error!
Post by: emanuele on December 04, 2018, 04:44:47 pm
You are using 7.something now, right?

Try replacing line 80 with:
Code: [Select]
$context['xml_data'] = $suggest->{$currentSearch['function']}();
If I'm not wrong this is the syntax.
Title: Re: Session Verification Error!
Post by: Auctor Lucan on December 04, 2018, 05:02:58 pm
Wohoo! That did the trick! :) Thank you so much, you're the best! Indeed, I am running on PHP 7.1.

Now I only have the 500 error when I try to edit Pages in Simple Portal.  :D Strange thing is that there is nothing in the error log there, so I'll have to try and do a fresh install or something, unless any more ideas come forth here.

Thanks again!
Title: SPLIT: Re: Session Verification Error!
Post by: emanuele on December 05, 2018, 03:11:43 am
One or more of the messages of this topic have been moved to Bug Reports (https://www.elkarte.net/community/index.php?board=2.0) - https://www.elkarte.net/community/index.php?topic=5482.0
Title: Re: Session Verification Error!
Post by: emanuele on December 05, 2018, 03:20:38 am
500 could be a "syntax error", by memory I don't remember what has changed between 5.x and 7.x that could have broken SP... maybe @Spuds can have an idea. :P