Friday, October 7, 2016

Python: working with Microsoft Active Directory using LDAP3 module

I'm giving a talk on programming against Microsoft Active Directory for my colleagues on Campus. Considering that most of them don't code in .NET, I decided it best to show them how to perform object queries and AD group membership tasks in a more common language. So I chose Python and the LDAP3 module.

It was fun figuring out the AD search filter format for objectGuids in a regular LDAP search and how to handle pulling membership for AD groups with over 1,500 members. The .NET way spoils me for sure. 

Here is a link to the demo code repo: