Django keep me login feature is not working

Question

Hi,
I want a solution if any anyone can assist me.
When customer will login with Keep me logged in checked then session will not be expire, But if Keep me logged in is not checked then should expire as per bellow mentioned setting.py variable value.

So Now login without checked keep me logged in is working fine as we have set SESSION_SECURITY_WARN_AFTER and SESSION_SECURITY_EXPIRE_AFTER. And if keep me login is checked, I tried to disable by overriding above variable value or increase expire time using request.session.set_expiry(24*30*3600). But it is not working. Can you anyone advice how can I disable this expire time if keep me login is checked.

settings.py

EXPIRE_TIME = 60*10
SESSION_SECURITY_WARN_AFTER = EXPIRE_TIME
SESSION_SECURITY_EXPIRE_AFTER = EXPIRE_TIME + 180
rajeshdas.rp@gmail.com June 7, 2017, 5:19 a.m. 0 Answer

Warning! You are not logged in.
Your answer will be published as Guest user.

Post your Answer

 Prev question