Page 1 of 1

Session failed to validate (incorrect IP)

Posted: 26 Apr 2013, 08:54
by antiKk
I'm running trunk currently and since switching from 1.7.8 I get logged out often.
It brings me back to the login screen and shows "Session failed to validate (incorrect IP)".

I use tt-rss at home and at work.
At home I do not have the issues.

I have tried different browsers and tried clearing cache etc..

tt-rss prefs > system > error log, doesn't seem to show anything.

Any suggestions?

Re: Session failed to validate (incorrect IP)

Posted: 26 Apr 2013, 11:54
by fox
Suggestion: try reading the error message.

Re: Session failed to validate (incorrect IP)

Posted: 26 Apr 2013, 13:09
by antiKk
That I have done.
Can you tell me which IP it thinks is invalid?
Server IP, Client IP?

Re: Session failed to validate (incorrect IP)

Posted: 26 Apr 2013, 13:40
by jakob42
I guess your clients IP has changed and the session is bound to that.

Re: Session failed to validate (incorrect IP)

Posted: 26 Apr 2013, 16:29
by dang
I get this whenever I move my laptop, so whenever it's IP changes. Just log in again.

Re: Session failed to validate (incorrect IP)

Posted: 26 Apr 2013, 16:49
by jdelamater99
antiKk wrote:That I have done.
Can you tell me which IP it thinks is invalid?
Server IP, Client IP?


Server IP probably doesn't change often. Most likely never changes. The session is tied to the client IP. Just log in again to initiate a new session with the current IP.

Re: Session failed to validate (incorrect IP)

Posted: 27 Apr 2013, 00:06
by lotrfan
Also see the 'SESSION_CHECK_ADDRESS' setting in config.php. By default, it checks the first three octets of the (client) IP when validating a session.

Re: Session failed to validate (incorrect IP)

Posted: 27 Apr 2013, 00:50
by aelg305
By default, it checks the first three octets of the (client) IP when validating a session


options:
-Try 2 instead of three
-if you are using a laptop, assign a static IP (not recommended) or get your mac and have the router always assign an specific IP to your TT-rss reading laptop! (most of the time when you resume a computer the ip may be renew as well)
-just log in and ignore it!

Re: Session failed to validate (incorrect IP)

Posted: 27 Apr 2013, 11:19
by jakob42
aelg305 wrote:-if you are using a laptop, assign a static IP (not recommended) or get your mac and have the router always assign an specific IP to your TT-rss reading laptop! (most of the time when you resume a computer the ip may be renew as well)

That only works if you have your ttrss installation locally available. If you have it on a server outside of your network your local IP should be meaningless. (Unless you got a small subnet from your provider and don't need to NAT, but I doubt that.)

Re: Session failed to validate (incorrect IP)

Posted: 27 Apr 2013, 13:07
by antiKk
Thanks for the replies everyone.

I'm pretty sure I know what it is now that I think about it.

I'm trialling using multiple gateways at work (each connects me out via a different ISP).
I could have been getting dropouts with primary and defaulting to the secondary.

This would give me a distinctly different WAN IP without me realising I was getting disconnected.

Re: Session failed to validate (incorrect IP)

Posted: 12 Jun 2013, 01:12
by Mirar
I'm not sure if I'm beating a dead horse here, but is there any way of skipping the IP part of the session so I can keep being logged in even though I switch IP? (I'm not particularly worried about that part of the security.) It's rather annoying if you're mobile and something you don't have control over keeps switching your IP number. To have that feature user-toggleable would be awesome.

Re: Session failed to validate (incorrect IP)

Posted: 12 Jun 2013, 09:41
by fox
Try reading through config.php.

Re: Session failed to validate (incorrect IP)

Posted: 12 Jun 2013, 10:44
by Mirar

Code: Select all

        define('SESSION_CHECK_ADDRESS', 0);                                     
        // Check client IP address when validating session:                     
        // 0 - disable checking                                                 
        // 1 - check first 3 octets of an address (recommended)                 
        // 2 - check first 2 octets of an address                               
        // 3 - check entire address                                             


Excellent, thanks.

Re: Session failed to validate (incorrect IP)

Posted: 03 May 2014, 10:04
by jannson48
I'm running TT-RSS on a Synology NAS on my home network and was getting this error as well. Running "netstat" on the NAS showed that it was picking up my client address in IPv6 format, even though I'd connected using the IPv4 address of the NAS.

Code: Select all

tcp        0      0 ::ffff:192.168.1.5%18:80 ::ffff:192.168.1.14%3203635604:61628 ESTABLISHED


Disabling SESSION_CHECK_ADDRESS in config.php stopped the error messages.