P is for Practical | |
PerlMonks |
Re: Authenticate Active Directoryby g0n (Priest) |
on Jul 19, 2006 at 16:17 UTC ( [id://562343]=note: print w/replies, xml ) | Need Help?? |
The simplest way is to gather the username and password, connect to your AD with Net::LDAP, and bind using the username and password. Check the result of the bind, if it was successful (!$result->code) the username and password are correct. Identifying whether that user is someone who should have permission to unlock someones account is another matter - you may want to create a group, and do a search for membership. For encrypted authentication, you need to connect to the AD with Net::LDAPS. The perl-ldap mailing list would be a good place to get help if you get stuck - in fact reading back through the list archives will get you a long way towards your objective.
--------------------------------------------------------------
"If there is such a phenomenon as absolute evil, it consists in treating another human being as a thing." Can you spare 2 minutes to help with my research? If so, please click here
In Section
Seekers of Perl Wisdom
|
|