Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from ldap3 import *
- import ssl
- tls_configuration = Tls(validate=ssl.CERT_REQUIRED,
- version=ssl.PROTOCOL_TLSv1)
- tls_configuration.validate = ssl.CERT_NONE
- s = Server('xxxxxx:389',use_ssl=False, get_info=ALL)
- c=Connection(s,user='xAdministrator',password='x',
- check_names=True,lazy=False,
- raise_exceptions=False)
- c.open()
- c.bind()
- c.add('cn=SubhasisB,ou=gssd users,dc=adldap,dc=com','User')
Add Comment
Please, Sign In to add comment