Srinivas Rao <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]
11/21/2003 11:09 AM
To: [EMAIL PROTECTED]
cc:
Subject: [Boston.pm] Q on authentication
Hi
I wrote a perl web application, and now I want
to add authentication to it. After some thought I
decided to do a textfile based authentication.
I wrote a script which asks for a username and password,
and the passwd file gets appended with username and
crypt(ed) password.
I tend to use Apache authentication. However sometimes it is good to use a
database-based (in this case flat file) authentication
I also wrote the web authentication part, where a form
accepts a username and password, and then reads the
passwd file, and checks if the passwd is correct or not.
Now If the password is correct, I want to redirect the user to
my application. How can I do this?
print "Location: <complete url>\n\n";
or using CGI.PM
$q->Redirect(url); where $q is a CGI object.
Also how can I prevent the user from directly executing
the main script(webapp). Is there a way I can maintain a session,
and in the beginning of each script check if session is valid or
not?
I use a cookie and redirect the user at the same time.
Again I use CGI.pm to constuct a cookie.
Thanks in advance
____________
Srinivas
,,,
(o o)
--ooO--(_)---Ooo-----------
"The average human has about one breast and one testicle." ? From
Statistics 101.
--oo0--------0oo-----------
_______________________________________________
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm
_______________________________________________
Boston-pm mailing list
[EMAIL PROTECTED]
http://mail.pm.org/mailman/listinfo/boston-pm