How to get password of active directory by ldap in php?

前端 未结 3 487
温柔的废话
温柔的废话 2021-01-12 18:29

I have problem about password in Active Directory. I want to get password from \"username\" of user I tried function \"ldap_search\", but I do not find correctly attribute f

3条回答
  •  北荒
    北荒 (楼主)
    2021-01-12 19:16

    I just queried an Active Directory (using ldapsearch in Ubuntu 10.04) running on a MS-Windows Server 2003, and it seem only the following can be retrieved and note that the password is not there.

    givenName
    distinguishedName
    instanceType
    whenCreated
    whenChanged
    displayName
    uSNCreated
    memberOf
    uSNChanged
    name
    objectGUID
    userAccountControl
    badPwdCount
    codePage
    countryCode
    badPasswordTime
    lastLogoff
    lastLogon
    pwdLastSet
    primaryGroupID
    objectSid
    accountExpires
    logonCount
    sAMAccountName
    sAMAccountType
    userPrincipalName
    

    You may also refer:

    • Using LDAP functions to get Active Directory tokenGroups attribute in PHP

提交回复
热议问题