Python Forum

Full Version: Python3/Flask/LDAP-Active Directory
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I need a cross-platform (Linux/Windows) method that allows me to perform LDAP/Active Directory queries in Python3. I need the following criteria:
  • Determine who the AD user is when the flask/app is running on a Linux platform
  • Find out what AD group(s) they are a member of
  • Normally hosted on a Linux platform, but same source could be hosted on Windows

I'm assuming this would be something using LDAP only (I want the same source to run in either environment - Linux or Windows).

I've been trying several things for the last couple days, and just seem to keep running into issues that either the methodology is specific to Python 2.x (python syntax errors - usually print command) and flat won't install/compile on Python 3.x, or its Windows specific, or...

Even installing python-ldap on Linux errors out that it can't find Python.h (and I can't install on Windows, since it says it requires Visual Studio 14(!?!?) )

I have NOT been able to successfully do anything is cross-platform. So - what SHOULD be used, and some examples?
Question misunderstood. Answer removed