[GeoNode-users] Logout of the application while user closes the browesr

Toni Schönbuchner toni.schoenbuchner at csgis.de
Wed Jul 19 01:23:36 PDT 2017


Hi Naresh,

make sure that you do not run into that issue:

Some browsers (Chrome, for example) provide settings that allow users to continue browsing sessions after closing and re-opening the browser. In some cases, this can interfere with the SESSION_EXPIRE_AT_BROWSER_CLOSE setting and prevent sessions from expiring on browser close. Please be aware of this while testing Django applications which have the SESSION_EXPIRE_AT_BROWSER_CLOSE setting enabled.


And that you realy close the browser:
see: https://stackoverflow.com/a/18541706/1474777

From what the docs say this setting should do exactly what you need.
If not you might propably implement something that fits your needs.

Unfortunately I´m still on travel and cannot have a look at a geonode
installation. All I can currently do for you… find here some resources which suggest implementations.

https://stackoverflow.com/questions/28754956/django-logout-user-when-they-leave-site <https://stackoverflow.com/questions/28754956/django-logout-user-when-they-leave-site>
https://stackoverflow.com/questions/14146396/django-session-expires-at-browser-close-or-after-time <https://stackoverflow.com/questions/14146396/django-session-expires-at-browser-close-or-after-time>
https://stackoverflow.com/questions/12768281/detecting-user-logout-on-browser-close-in-django <https://stackoverflow.com/questions/12768281/detecting-user-logout-on-browser-close-in-django>
https://stackoverflow.com/questions/3024153/how-to-expire-session-due-to-inactivity-in-django/25322730 <https://stackoverflow.com/questions/3024153/how-to-expire-session-due-to-inactivity-in-django/25322730>

cheers,

Toni


-----------------------------------------------
CSGIS

-----------------------------------------------
Kolonnadenstraße 1
04109 Leipzig
-----------------------------------------------
Mobil	+49/ (0) 176 6680 3198
Tel 		+49/ (0) 341 24 04 738
Fax 		+49/ (0) 341 24 04 73
Web		http://csgis.de
-----------------------------------------------

Hinweis gemäß § 33 BDSG
Daten der Verfahrensbeteiligten werden gespeichert. Dieses Dokument ist ausschließlich für den
Adressaten bestimmt. Der Inhalt der E-Mail ist vertraulich. Falls Sie diese E-Mail versehentlich
erhalten haben, rufen Sie uns unter obiger Rufnummer umgehend an und löschen Sie diese Nachricht
von Ihrem Computer. Jegliche Art von Reproduktionen, Verbreitung, Vervielfältigung, Veränderung,
Verteilung und/oder Veröffentlichung dieser E-Mail ist verboten.

> Am 19.07.2017 um 09:41 schrieb Naresh N <naresh919 at gmail.com>:
> 
> Dear Toni,
>  Thanks for the response. I have included in GeoNode settings.py and localsettings.py, but it is not working, I mean on close of the browser session is not removed.
> 
>  Is there any work around
> 
> Thanks&Regards,
> Naresh
> 
> 2017-07-19 12:04 GMT+05:30 Toni Schönbuchner <toni.schoenbuchner at csgis.de <mailto:toni.schoenbuchner at csgis.de>>:
> Hi Naresh,
> 
> I´m not much familiar with the login system of geonode but as it´s
> based on django you could give
> 
> SESSION_EXPIRE_AT_BROWSER_CLOSE = True
> 
> in your settings a try.
> Read more here:
> https://docs.djangoproject.com/en/1.11/topics/http/sessions/#browser-length-sessions-vs-persistent-sessions <https://docs.djangoproject.com/en/1.11/topics/http/sessions/#browser-length-sessions-vs-persistent-sessions>
> 
> Best,
> 
> Toni
> 
> -----------------------------------------------
> CSGIS
> 
> -----------------------------------------------
> Kolonnadenstraße 1
> 04109 Leipzig
> -----------------------------------------------
> Mobil	+49/ (0) 176 6680 3198
> Tel 		+49/ (0) 341 24 04 738
> Fax 		+49/ (0) 341 24 04 73
> Web		http://csgis.de <http://csgis.de/>
> -----------------------------------------------
> 
> Hinweis gemäß § 33 BDSG
> Daten der Verfahrensbeteiligten werden gespeichert. Dieses Dokument ist ausschließlich für den
> Adressaten bestimmt. Der Inhalt der E-Mail ist vertraulich. Falls Sie diese E-Mail versehentlich
> erhalten haben, rufen Sie uns unter obiger Rufnummer umgehend an und löschen Sie diese Nachricht
> von Ihrem Computer. Jegliche Art von Reproduktionen, Verbreitung, Vervielfältigung, Veränderung,
> Verteilung und/oder Veröffentlichung dieser E-Mail ist verboten.
> 
>> Anfang der weitergeleiteten Nachricht:
>> 
>> Von: geonode-users-request at lists.osgeo.org <mailto:geonode-users-request at lists.osgeo.org>
>> Betreff: geonode-users Digest, Vol 30, Issue 73
>> Datum: 19. Juli 2017 um 06:10:54 MESZ
>> An: geonode-users at lists.osgeo.org <mailto:geonode-users at lists.osgeo.org>
>> Antwort an: geonode-users at lists.osgeo.org <mailto:geonode-users at lists.osgeo.org>
>> 
>> Message: 1
>> Date: Wed, 19 Jul 2017 09:40:51 +0530
>> From: Naresh N <naresh919 at gmail.com <mailto:naresh919 at gmail.com>>
>> To: "geonode-users lists.osgeo.org <http://lists.osgeo.org/>" <geonode-users at lists.osgeo.org <mailto:geonode-users at lists.osgeo.org>>,
>> 	Simone Dalmasso <simone.dalmasso at gmail.com <mailto:simone.dalmasso at gmail.com>>,  Alessio Fabiani
>> 	<alessio.fabiani at geo-solutions.it <mailto:alessio.fabiani at geo-solutions.it>>
>> Subject: Re: [GeoNode-users] Logout of the application while user
>> 	closes the	browesr
>> Message-ID:
>> 	<CAKAPXzMsk1Qye6XKod4CYbU1hKSNGAvouw+4Eb34JkA9LzQ+8Q at mail.gmail.com <mailto:CAKAPXzMsk1Qye6XKod4CYbU1hKSNGAvouw+4Eb34JkA9LzQ+8Q at mail.gmail.com>>
>> Content-Type: text/plain; charset="utf-8"
>> 
>> Dear Simone,
>> Kindly suggest for my post.
>> 
>> Thanks&Regards,
>> Naresh
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20170719/dac9e3c4/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20170719/dac9e3c4/attachment-0001.sig>


More information about the geonode-users mailing list