242 questions
0
votes
0
answers
30
views
What's the ldap query for ldapsearch to fetch MinPwdLen attribute from windows adserver?
How can the query be found to get the value of attributes like MinPwdLen, MinPwdAge, etc., from a Windows AD server? I got the distinguished name for this attribute from JXplorer, but I'm unable to ...
0
votes
0
answers
108
views
How to check, the metadat of a WHL file (python library package) in order to know what it wants for : platform, interpreter and version
I know, you'd ask why I would want to this, so I have a WHL file to install on windows with a title like :
nameAndVersion-cp38-cp38-win_amd64.whl
Sadly, it does not install the result is :
Error "...
0
votes
0
answers
132
views
Unable install python-ldap in python 2.7.9 on windows 11
I cannot install the required package because it needs Visual Studio C++ 9.0, which is no longer supported. Unfortunately, I can't upgrade my Python version because I need it for Odoo 8 development. ...
0
votes
1
answer
53
views
Search which groups is the AD user member of
I need to authorize the user in AD and receive the list of groups which is the user member of. I have done the code working, but the search takes very long - about 20 seconds in my small office AD ...
0
votes
0
answers
114
views
python-ldap coudl't be installed
I'm trying to install python-ldap, but this raise an error:
"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\bin\HostX86\x64\cl.exe" /c /nologo /O2 /...
0
votes
2
answers
2k
views
python_ldap install failure on windows using whl file
The python_ldap package for windows 10 fails to install on my windows laptop. It exits with error C1083: mysql.h not found. So I adjusted the path order to place the location of this file closer to ...
0
votes
1
answer
597
views
python ldap3 authentication sometimes succeed and sometimes fails
I'm trying to verify a user with ldap3 with the next Python code, sometimes it goes to the 'Authentication successful' message, and sometimes it fails and goes to the 'LDAP search failed' with the ...
1
vote
1
answer
2k
views
LDAP Signing with LDAP3 module in python
I am using LDAP3 module to query information from Active Directory. To get information like GMSA password blob(ManagedPassword attribute), Active Directory expects that either connection is secure(...
13
votes
5
answers
43k
views
ERROR: Could not build wheels for python-ldap, which is required to install pyproject.toml-based projects
I was installing Odoo 15 inside a Python virtual environment on Ubuntu 20.04. I've downloaded Odoo from the official GitHub repository and use Nginx as a reverse proxy.
after following the ...
-1
votes
1
answer
598
views
ldap search_filter escape specific charter [duplicate]
I retrieve members of a group and their sAMAccountName (NT Accounts) I run the following code takes from: ldap3 python search members of a group and retrieve their sAMAcountName (Active Directory)
I'm ...
0
votes
0
answers
135
views
Strange output of pwdLastSet
Some of AD accounts are inactive and their pwdLastSet is equal to 0.
However, when I'm trying to calculate password age for accounts, this inactive accounts gave me a last possible date 1601-01-01 00:...
0
votes
1
answer
196
views
LDAP Filter Syntax Query
What would be the syntax for LDAP for the below scenario:
Where sAMAccountName = GRA-* without $. I want the records which are highlighted in green.
This is my current LADP Filter for your reference:
...
0
votes
1
answer
66
views
Problem with Python script when setting up LDAP for MacOS
I am trying to set up Google secure LDAP on my Macbook Pro running Monterey 12.3 following these instructions from Google.
request.appendData_(NSData.dataWithBytes_length_(CONFIG,
len(CONFIG))) ...
1
vote
1
answer
716
views
How to get the list of possible operational attributes for an objectClass with python-ldap?
With this python snippet, I can get the list of all the available objectClasses in a LDAP server:
import ldap
conn = ldap.initialize("ldap://127.0.0.1:389")
conn.simple_bind_s("cn=...
1
vote
1
answer
444
views
Can somebody help me with python-ldap initialize process?
I am using OpenSuse Tumbleweed and try to connect my pythons script with an ldap server.
following my code:
import ldap
connection = ldap.initialize("*address*")
But i got following error:
...
1
vote
1
answer
1k
views
Why does python-ldap code raise the Exception ldap.REFERRALS?
I'm trying to use the python-ldap library to connect to an Active Directory Server.
I'm using the code found in this link.
Authentication by simple bind
The following code works correctly:
con = ldap....
1
vote
1
answer
7k
views
What's the best way to write an LDAP client in Python
I don't know LDAP but I need to develop an application (essentially a LDAP client) for authentication on an LDAP Server and perform a query/search in the directory managed by the LDAP Server.
My ...
2
votes
0
answers
537
views
Python-ldap Authentication doesn't need password
I have been researching on how to implement an authentication using python-ldap. Upon trying some codes and reading the documentation I've come up with the code below, upon testing, it always return &...
0
votes
0
answers
3k
views
Confusion about "python3-ldap" and "ldap3"
We have an older app that is running on a Redhat 7 machine and was originally written in python 2.x and imports and uses "ldap3".
We are now starting to upgrade to Redhat 8 and since it ...
0
votes
1
answer
1k
views
AWS Lambda python ldap query
try to find user information from ldap, but I get the timed out error. locally it is working
I've tried with both python-ldap and ldap3
at this moment, I am confused as I see some documentation and ...
0
votes
1
answer
1k
views
Pattern matching in LDAP Distinguished Name Template
I am trying to authenticate users using django_auth_ldap. I have users in 2 different groups (say= Theta & Gamma, Alpha & Rho),
Currently, to search users I have created 2 authentication ...
2
votes
1
answer
570
views
Unable to set “User cannot change password“ ACE with python ldap3
I am trying to create a service account via the Ldap3 library in Python. The service account is successfully created, but there is a small problem. The "User cannot change password" ...
0
votes
0
answers
284
views
Changing AD user password when "Password must change at next logon"is checked using ldap3
I am working on an application which uses ldap3 to authenticate AD user and warn the users about their password expiry date. This works fine.
The issue happens when the user has checked "Password ...
0
votes
0
answers
133
views
Is there a way to decide local interface/IP address to be used in python ldap client?
My Vm have multiple interfaces and I need to choose a particular interface to be used with python ldap client. But I didn't find any way on how to specify an interface for ldap client. Each time it ...
0
votes
1
answer
1k
views
LDAP search takes too long
I'm trying to get more than 50.000 records from LDAP (with python-ldap and page control tools).
I have searching filter, which is
(|(field=value_1) (field=value_2)...(field=value_50000)
But this ...
0
votes
0
answers
714
views
ldap.INVALID_DN_SYNTAX error when I try to create an AD user with python ldap
I have an error when I try to create a new user in my active directory with python ldap. The connection to the server works since the search function works.
Here is my code, I apologize in advance if ...
1
vote
0
answers
241
views
Unable to create Lambda layer with python-ldap library
I am trying to create a lambda layer with python-ldap and I am getting error:
docker run -v "$PWD":/var/task "public.ecr.aws/sam/build-python3.9" /bin/sh -c "/var/lang/bin/...
2
votes
0
answers
1k
views
Unable to install python ldap module on windows
Tried installing python-ldap, but failed
"C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG ...
0
votes
2
answers
568
views
Issue Querying LDAP from Unix Bash using Python
I am reading a csv file containing list of employees(GRCLOGIN.csv) and retrieving employee ID to Query LDAP to retrieve their related data and save it to a text file(LDAP_USERS.txt)
from sys import ...
2
votes
2
answers
5k
views
Can't install python-ldap in Docker
I'm getting the following error when trying to install python-ldap module in Docker image for aws:
In file included from Modules/LDAPObject.c:3:0:
Modules/common.h:15:10: fatal error: lber....
1
vote
0
answers
849
views
Python ldap delete computer object
I am currently trying to delete some computer objects from the AD using python LDAP when they are deleted/decommissioned (basically any cloud instance which joins our on-pre AD domain upon creation ...
0
votes
1
answer
2k
views
Is it possible to do ldap query and exclude certain OU?
Using python-ldap to search active directory. How do I exclude certain user with a specific OU?
Searching within the group 'GON' and want it to return just regular users with OU=Users and not OU=Foo.
...
0
votes
1
answer
3k
views
I cant import LDAP module in Python
i installed python-ldap and ldap3 :
(einstieg) C:\Users\User\Python\modules>pip freeze
ldap3 @file:///C:/Users/User/Python/modules/ldap3-2.9.1-py2.py3-none-any.whl
pyasn1 @
file:///C:/Users/User/...
0
votes
1
answer
334
views
Can we check whether a user is part of an Organizational Units instead of Groups in Django LDAP?
In my LDAP directory, Users are added to Organizational Units instead of groups. How can I check whether a user is a part of an Organizational Unit using Django LDAP ?
My settings.py file:
...
0
votes
2
answers
2k
views
python-ldap stronger authentication
I'm trying to make a search in our AD with python-ldap.
When I try to make the:
connect.simple_bind_s('ldap_login', 'ldap_password')
I am getting the error:
ldap.STRONG_AUTH_REQUIRED: {'msgtype': 97,...
0
votes
1
answer
530
views
Script to find the user who does not have uid (User ID) in LDAP server
I wrote a python script to find out the users who does not have uid (User ID) in the ldap server but I am getting weird results.
from ldap3 import Server, Connection, ALL
import csv
server = Server('...
0
votes
1
answer
476
views
Can returned attributes be forced into lowercase
Changes on our LDAP Server have changed the case of the attributes returned from search. For example, "mailroutingaddress" is now "mailRoutingAddress". The searches themselves are ...
4
votes
1
answer
2k
views
python-ldap 3.4 installation fails on alpine images
When trying to install the latest python-ldap version 3.4 on an apline docker image (I use python:3.9-alpine as my base image) the build of python-ldap fails with:
...
/usr/lib/gcc/x86_64-alpine-linux-...
1
vote
2
answers
337
views
How to install a LDAP schema with python-ldap?
I have a LDAP schema in a .ldif file that I would like to use python-ldap to install the schema on my LDAP server. My context is the installation process of a python application that needs some custom ...
0
votes
2
answers
2k
views
Process LDIF modify records with python-ldap
I am using python-ldap to process an LDIF file and (conditionally) import the records from that file into an LDAP server. Every piece of documentation and every example I can find, just assumes LDIF ...
0
votes
1
answer
839
views
How to troubleshoot a failing Django LDAP connection
I am using Django Rest with active directory authentication.
I have built a simple app with the following settings:
import ldap
from django_auth_ldap.config import LDAPSearch, GroupOfNamesType
# ...
1
vote
1
answer
3k
views
libldap_r-2.4.so.2 missing when importing python-ldap on AWS
I just cant get python-ldap to work inside AWS-Lambda. I have a simple Lambda script:
import ldap
def main():
print("Success")
and a Layer I built on an EC2 AmazonLinux2 (which works ...
1
vote
1
answer
703
views
Install a python module in the same directory as the main handler
Hello I want to install a module named python-ldap locally in the same directory as my main so that it could be zipped and uploaded as a standalone function. The reason is AWS Lambda doesn't support ...
0
votes
0
answers
2k
views
How to get a user from local AD using ldap3?
I am trying to get a particular user from AD using the ldap3 python module. Here is how I am trying to do it:
from ldap3 import Server, Connection, ALL
srv = Server('company.com', get_info=ALL)
conn =...
0
votes
0
answers
329
views
Python LDAP: Get all group memberships recursively
Using Python LDAP, how do I get all the groups a user is a member of, recursively.
For example if a user is member of the group "Zurich", which is part of the group "Switzerland", ...
1
vote
1
answer
693
views
Import ldap in python gives gives "DLL load failed" error
I'm using the "import ldap" in a python code. This is on a windows 10 machine.
I installed the python-ldap module
pip3 install python-ldap
Installed the dependencies based on the ...
0
votes
2
answers
4k
views
trying to parse ldif file using python-ldap ldifparser
I have ldif file as below, I want to extract only the dn and changetype here using the ldif parser of python-ldap package.
dn: cn=abc, cn=def, cn="dc=grid,dc=mycompany,dc=com", cn=tree, cn=...
0
votes
1
answer
1k
views
Error when installing python ldap package
I am trying to install python-ldap on ubuntu 20.04
pip3 install python-ldap
It complains about this command error
x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -...
0
votes
1
answer
956
views
Odoo 14 on windows can't enable LDAP Authentication
I tried to enable LDAP Authentication on ODOO 14 which is install on Windows Server and when click save i got the following error
"Error:
Odoo Server Error
Traceback (most recent call last):
...
2
votes
1
answer
344
views
Turn off search continuation results in python-ldap?
Using python-ldap.search_s() function (https://www.python-ldap.org/en/python-ldap-3.3.0/reference/ldap.html#ldap.LDAPObject.search_s) with params...
base = DC=myorg,DC=local
filterstr = (&(...