[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

PHP and http auth



-----BEGIN PGP SIGNED MESSAGE-----


Whelp, I figured out how to get the authenticated user handle in PHP when
using mod_perl authentication.  The following magic gets it done in PHP:

$user = getenv("REMOTE_USER");

I'm trying to port Micah's scripts over to use this, instead of using PHP
logic to query the DB to do the http auth, but to be honest I'm kinda lost
trying to decode some of Micah's code.  (For some reason the same syntax
doesn't always work when I try it ;-)  

Anyways, now that we know it will work, I'm going to try to figure the
rest of it out.  If someone who's more PHP knoweldgeable wants to take
over, by all means let me know.  

Poor Micah isn't going to recognise his scripts when he gets back. :-)


- -- 
Aaron Turner           | Either which way, one half dozen or another. 
aturner@pobox.com      | Check out the Red Hat Linux User's FAQ Online!
www.pobox.com/~aturner | http://www.pobox.com/~aturner/RedHat-FAQ/
All emails from this account are PGP signed.  Lack of a signature is "bad".
PGP Key fingerprint = FB E1 CE ED 57 E4 AB 80  59 6E 60 BF 45 1B 20 E8



-----BEGIN PGP SIGNATURE-----
Version: 2.6.2

iQCVAwUBNxbWXDM3jpXy1kJtAQEhIgP/W+D81bQbXg1Mx2IrFGAnyjH2t57K9/HR
Z51JJr+gr8wn7YVgj7PbNfpTNK5C0ICT/USxIQqEhhKXw4eYkYtledb7daXHNsi8
J+8GuetXFouj9B+VDIttlXq+eZSCNfCtetj7IpZg5pwO/o1KoyZJ76szPgI5dCud
+1hQll8LgIA=
=J9Ks
-----END PGP SIGNATURE-----