I am using Django with the Allauth login code (and still a bit wet) to perform authentication. It appears that if you check "remember me", it does the following in the allauth login form:
allauth forms.py (class LoginForm)
if remember:
request.session.set_expiry(app_settings.SESSION_COOKIE_AGE)
else:
request.session.set_expiry(0)
return ret
I am trying to use the "remember me" for other features in my app. It appears that the only 'flag' I have to determine if a user wants to be remembered or not is the above value.
In my view code, I tried to read this 'flag' with the following command:
request.session.get_expiry_age()
Unfortunately, it always returns 1209600. Whether the user checks the "remember me" box or not, this value is 1209600.
I need to find this flag so that I can use it in several places. What system variable is set and exposed when a user checks this 'Remember me' box that I am not seeing?