Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: CGI Authenticaiton

by InfiniteSilence (Curate)
on Feb 09, 2012 at 19:08 UTC ( #952813=note: print w/replies, xml ) Need Help??


in reply to CGI Authenticaiton

..timing out the users session...

Read the perldoc for CGI::Session, not just the first part of it, but the entire thing like the section on the expire() method.

...The problem I have then is ... and/or stopping anyone logging in with the same id....

CGI::Session stores things about the connecting session, hence you will know the IP address of the client that created the session and can, whenever validating that session on every subsequent request, check it again. If it is not the same then deny the request (see remote_addr() in the perldoc).

Celebrate Intellectual Diversity

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://952813]
help
Chatterbox?
[atcroft]: PriNet: %hash = ();? or foreach my $k ( keys %hash ) { delete $hash{$k}; }?
[PriNet]: go figure, i just tried that, it retains some of the values (not the key) of the pre-assigned value

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (2)
As of 2017-06-28 02:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (619 votes). Check out past polls.