in reply to Re^2: Perl Sessions and Cookies - Cookie don't get passed
in thread Perl Sessions and Cookies - Cookie don't get passed
To prevent XSS attacks you should have a 'logged in' hidden input. Clear this input to logout, leave the Cookies as they are.
It's been awhile since I've worked with HTTP sessions, but if memory serves you should be putting the last login name into a cookie and the "this user is logged in" data into form fields or a this cookie is logged in untill after on the server.
You definitely should not be using cookies to determine if a user is logged in, that much I remember clearly. You need either server side session or form variables. Place a "good for so long" password hash into an HTML hidden input and you'll do just fine.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Perl Sessions and Cookies - Cookie don't get passed
by Anonymous Monk on Mar 06, 2015 at 13:41 UTC | |
by cheako (Beadle) on Mar 06, 2015 at 18:31 UTC | |
by karlgoethebier (Abbot) on Mar 07, 2015 at 17:06 UTC | |
by cheako (Beadle) on Mar 07, 2015 at 22:11 UTC | |
by Anonymous Monk on Mar 08, 2015 at 14:01 UTC | |
|