I'm trying to rename AD user Test_2 to testing using python LDAP3 as well as moving user to another OU too.
NOTE: instead of domain name i am using IP and rest is same.
i am successfully able to fetching user details using the same manner (Mentioned in NOTE), but during renaming and moving user one OU to other OU, i am getting negative result; the funny thing is code doesn't showing any error it is showing only FALSE result.
import ldap3
from ldap3 import Server, Connection, ALL
server=Server(host='IP',port=389,get_info=ALL)
conn=Connection(server,user='adtest\admin',password='admin@123') conn.bind()
print (conn.modify_dn('cn=Test_2,OU=Test,OU=adtest','cn=Testing'))