1.7.9 - Session failed to validate

Support requests, bug reports, etc. go here. Dedicated servers / VDS hosting only
projectdelphai
Bear Rating Trainee
Bear Rating Trainee
Posts: 4
Joined: 18 Mar 2013, 09:50

1.7.9 - Session failed to validate

Postby projectdelphai » 18 May 2013, 05:53

Note: I am hosting on Heroku and that may be why I had this problem.

I did a fresh install of 1.7.9 and when I tried to log in (admin:password), it failed with the error message "Session failed to validate (invalid IP)". I tried a fresh install of 1.7.5 which is the version I was using before (I know it took me a while to update, my fault) and I didn't encounter this problem.

I fixed it for me by remove the necessary lines in include/sessions.php under function validate_session().

Code: Select all

   if ($check_ip && strpos($_SERVER['REMOTE_ADDR'], $check_ip) !== 0) {
             $_SESSION["login_error_msg"] =
              __("Session failed to validate (incorrect IP)");
             return false;
         }

I don't if there is a better way to do this or why it happened though.

cqrt
Bear Rating Disaster
Bear Rating Disaster
Posts: 70
Joined: 05 Apr 2013, 00:37

Re: 1.7.9 - Session failed to validate

Postby cqrt » 18 May 2013, 06:24

I think if you had cleared your cookies and reloaded your login page, you should have had no issues logging in. Attacking the base code with a meat cleaver is definitely not the answer.

User avatar
fox
^ me reading your posts ^
Posts: 6318
Joined: 27 Aug 2005, 22:53
Location: Saint-Petersburg, Russia
Contact:

Re: 1.7.9 - Session failed to validate

Postby fox » 18 May 2013, 09:18

You can also disable address checking in config.php if it doesn't work for some reason.

projectdelphai
Bear Rating Trainee
Bear Rating Trainee
Posts: 4
Joined: 18 Mar 2013, 09:50

Re: 1.7.9 - Session failed to validate

Postby projectdelphai » 18 May 2013, 19:08

Thanks, I'll disable it.

cqrt: That was my first response. I tried clearing the cookies and my cache, then trying a new browser, then a fresh install and nothing worked. Missed the config option though.

durval
Bear Rating Trainee
Bear Rating Trainee
Posts: 26
Joined: 27 Jul 2013, 13:35

Re: 1.7.9 - Session failed to validate

Postby durval » 20 Aug 2015, 19:18

Howdy,

TWIMI, I had the same issue here: an infinite loop of "Session failed to validate (incorrect IP)" errors, even while I was pretty sure the my address wasn't changing between attempts.

What I did was to change, in the TT-RSS config.php:

From this:

Code: Select all

define('SESSION_CHECK_ADDRESS', 1);


To this:

Code: Select all

define('SESSION_CHECK_ADDRESS', 0);


And then I was able to login, at the cost of no more session address checking.

PS: Running TT-RSS v. 1.8 here.

Cheers,
--
Durval.


Return to “Support”

Who is online

Users browsing this forum: No registered users and 4 guests