I am running Perl as a CGI (and, yes, I have begged and begged Sys. Admin's to get mod_perl on there, but to no avail) on Apache. I have a page where user's can go to and modify some of their own LDAP attributes. Before they reach the page, Apache challenges them for authentication (via mod_auth_kerb). Once they are authenticated, I can look in
$ENV{'REMOTE_USER'} to get their username and run a query against LDAP via this trimmed down code:
my $ldapObj = Net::LDAP->new($server);
$ldapObj->bind; # bind anonymously
my $ldapSearchUser = $ldapObj->search(base => 'o=isp',
filter => '(uid=' . $ENV{'REMOTE
+_USER'}. ').);
After they make some modificatication(s) to their information, I need to bind back to the LDAP server as the user who logged on to the web page. Something like:
$ldapObj->bind($dn, $ENV{'PASSWORD'})
The problem being, there is no
$ENV{'PASSWORD'}. Is there any way I can get Perl (as CGI) to access the password the user logged in with?
Thanks,
enoch