Registry / security / msldap

msldap

JSON →
library0.5.15pypypiunverified

Python library to play with Microsoft LDAP, commonly used in offensive security tooling (e.g., pypykatz). Current version 0.5.15, released irregularly. Requires Python >=3.7.

pip install msldap
INSTALL
IMPORT
SIG · MSLDAP
M
msldap
securitypythonv0.5.15
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

MSLDAPClient
from msldap import MSLDAPClient
from msldap import MSLDAPClient

Connect to an MS LDAP server using password authentication.

import asyncio from msldap import MSLDAPClient async def main(): client = MSLDAPClient( 'ldap://192.168.1.1', 'DOMAIN\\username', 'password' ) _, conn = await client.connect() print('Connected successfully') await conn.disconnect() asyncio.run(main())
Debug
Known issues
breakingIn v0.5.x, the import path for MSLDAPClient changed. Code using 'from msldap.client import MSLDAPClient' will break.
fix
Use 'from msldap import MSLDAPClient' instead.
affects: >=0.5.0
gotchaThe library uses asyncio; synchronous wrappers may not exist. Always run in an async context.
fix
Wrap calls with asyncio.run() or use await inside async functions.
affects: all
deprecatedThe 'msldap.ldap_objects' submodule is deprecated and may be removed in future versions.
fix
Use 'msldap.protocol' instead.
affects: >=0.5.0
Upgrade
Version history
0.5.15latest on PyPI · released May 25, 2025
Audit
Dependencies

No dependency data recorded yet.

Agent activity
10 hits · last 30 days
node
10
Resources
msldap — pip install msldap · libregistry