Advertisement
Guest User

Untitled

a guest
Aug 2nd, 2016
222
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. from ldap3 import *
  2. server = Server('myldapserver.com', get_info=ALL)
  3. the_user = 'cn=Manager,dc=domain,dc=com'
  4. conn = Connection(server, the_user, password='adminpass')
  5. conn.bind()
  6.  
  7. user = 'cn=testuser,ou=People,dc=domain,dc=com'
  8. conn.extend.microsoft.modify_password('cn=testuser,ou=People,dc=domain,dc=com', None, 'newpassword')
  9. print(conn.result)
  10.  
  11. ldap3.core.exceptions.LDAPAttributeError: invalid attribute type in attribute
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement