Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Authentication

by mkilic (Initiate)
on May 09, 2001 at 22:13 UTC ( #79188=perlquestion: print w/replies, xml ) Need Help??

mkilic has asked for the wisdom of the Perl Monks concerning the following question:

Hello, I need to come up with a progam that would login a page, browse throught the site and download some documents. I have a problem with authentication. I don't know how to keep the connection alive. I also need to figure out a way to keep session alive. Is there anybody who has done stuff like this? I will appreciate nay help on this matter. Thanks, Mak

Replies are listed 'Best First'.
Re: Authentication
by tinman (Curate) on May 09, 2001 at 22:23 UTC

    There are several nodes that I know of that address this issue.. The following links are ones that you might find interesting/useful to you...

    Login encryption and CGI understanding
    CGI Password

    A Super Search on this topic will surely turn up some more informative posts...

    The short version is: You can use SSL (Secure Sockets Layer, also known as Secure HTTP (https) to authenticate/encrypt a session). You can also use cookies and session variables, so there is no real need to keep a connection alive...

    Simply, prompt the user for a username/password, set a special variable (either through a cookie or some other mechanism) on the client so that you know the person has logged in ok... thereafter, whenever a request is made to the browser, check for the existence of this special variable and its value.. a person who has not logged in properly will not have this special session variable set..once the person logs out, unset this variable...
    HTH

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://79188]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (7)
As of 2020-07-02 11:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?