#在ldap里类似cn=username,ou=users,dc=gccmx,dc=cn,验证用户密码,必须先检索出该DN
def ldap_search_dn(self,uid=None):...],
# 'userPassword': ['{MD5}lueSGJZetyySpUndWjMBEg=='],
# 'cn': ['django'], 'sn': ['django..., e:
print e
#查询用户记录,返回需要的信息
def ldap_get_user(self,uid=None):
obj = self.ldapconn...0]
email = result_data[0][1]['mail'][0]
nick = result_data[0][1]['sn..., e:
print e
#用户验证,根据传递来的用户名和密码,搜索LDAP,返回boolean值
def ldap_get_vaild(self,uid=None