PDA

View Full Version : I have a big problem



Epgs
November 25th, 2000, 15:49
Ok is there any way to link two password protected areas together so that when you are logged into one you can go to the other without having to log in again? Is there a password cgi-script that will do it. Like place a uniform cookie in the computer so that both scripts will notice the person.

Thank you

[Edited by Peo on 11-25-2000 at 05:04 PM]

melz
November 25th, 2000, 15:53
why not use .htaccess?
and have they reference to the same .htpasswd file.

melz.

[Edited by Peo on 11-25-2000 at 05:04 PM]

atlas
November 25th, 2000, 19:10
Originally posted by Epgs
Ok is there any way to link two password protected areas together so that when you are logged into one you can go to the other without having to log in again? Is there a password cgi-script that will do it. Like place a uniform cookie in the computer so that both scripts will notice the person.

Thank you

[Edited by Peo on 11-25-2000 at 05:04 PM]

Yes, usually this is done with a cookie and a session. Authenticate a session for a given user, and then have a cron script expire all sessions past a certain time (like 2 hours), so they need to re-authenticate. Have all scripts that want to authenticate use that same sessions file.

I don't know if I explained this very well for you, tell me if you don't understand.

mjk@atlascgi.com