I got two lines, one is: https://stackoverflow.com/a/27288275/728750
The above link is saying:
It is possible , Facebook, Gmail have done that , But it is not simple.
Use a flag in the database that checks users on Session_Start that invalidates their session
If that flag is set. May not necessarily use a Boolean, you can use a DateTime value and
invalidate all sessions that started prior to that time. This could be done by checking a value stored in a cookie upon login.
What they trying to say is not clear.
How to implement this "you can use a DateTime value and invalidate all sessions that started prior to that time."?
How to know when user session was started?
I got a another good link: https://stackoverflow.com/a/5492396/728750
This line is not clear:
authCookie.Expires < logoutTime.Value
How the above line would works? Suppose I login to web site now and today date is 01/01/16 and login expire date is 07/01/16 and I force logout on 02/01/16 then how this expiry date 07/01/16 would be less than force logout date 02/01/16. This is not clear. Can anyone help me implement this? Thanks.