Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re^2: Using CGI::Session for authentication

by rjsaulakh (Beadle)
on Jun 24, 2005 at 09:56 UTC ( [id://469655]=note: print w/replies, xml ) Need Help??


in reply to Re: Using CGI::Session for authentication
in thread Using CGI::Session for authentication

rlucas i am too working with the same CGI::Session but i find myself no where as far as you say that
your best bet is to always, no matter what, print your header as including a cookie containing the CGISESSID (or whatever you've decided to name it).
i have reached sucess still this point i am able to print the cookie which i am sending to the user
but the problem is that on subsequest pages when i try running the same script it creates a new session rather than intiallizing the existing one . i would like to add that i am not able to fetch the cookie
i dont know whether my understanding is wrong or my handling of the code is wrong .
my code is almost similar to the one posted with this node kidly guide

Replies are listed 'Best First'.
Re^3: Using CGI::Session for authentication
by rlucas (Scribe) on Jun 24, 2005 at 21:53 UTC
    You need to find out exactly what is happening. I recommend that you begin a fresh session with cookies cleared from browser and browser set to ask you for each cookie. Also, use file-based Data::Dumper serialization (for transparency in observing file contents) in CGI::Session and clear out the session directory. (Clean initial condition) Finally, make sure to write the received cookie info to the error log so that you can tell when your app either sets (via browser asking you) or receives (via server error log) a cookie.

    Then, go to the app and observe the cookie that is set and the file that is created. Go again to the app, verify that the cookie that was set is indeed sent back, and processed properly. Verify that the same cookie gets set again with identical session ID value.

    The answer for you will be found wherever this breaks down. Good luck.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2024-03-29 06:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found