Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
April 28, 2005, 4:20 pm
rate this thread
I created a set of pages with PHP for login using a database. Now, I
link to a lot of CGI programs in a folder with protected-access
username and password are the same as the ones people use to login
with. Is there a way to use the session usrname/password for the HTTP
authentication to that folder ?? If I remove the .htaccess for that
particular folder, then all those files will have access without any
kind of authentication.
I tried username:email@example.com . But this doesnt work with
IE 6. So I need something else.
*** psk79 wrote/escribió (28 Apr 2005 11:20:29 -0700):
I've not really understood what you're trying to accomplish. With Apache
you can password protect CGI files the very same way you protect any other
type of resource: copy your .htaccess file to your cgi-bin folder or any
Maybe you want to write a CGI script that makes use of HTTP authentication.
There must probably be some pre-written libraries out there; the method
itself is not hard to implement, but you need to find and read the RFC
document (you must send an specific HTTP header with auth info). You can
also connect with a browser and sniff the header sent by it. The
LiveHTTPHeaders extension for Mozilla/Firefox makes so very easy.
All modern browsers allow you to store passwords, you don't need to add it
to bookmarks, if that's what you mean.
-- Álvaro G. Vicario - Burgos, Spain
-- http://bits.demogracia.com - Mi sitio sobre programación web
-- Don't e-mail me your questions, post them to the group