Query users and/or groups DN from Active Directory.
Because basic LDAP query is out of MS' scope...
Author(s): Tamas Bures | Created: 17 April 2019 | Last modified: 21 December 2024
Tested on: -
Table of contents
Query users and/or groups DN from Active Directory.↑
- Open a Windows Command Prompt.
- Use the following command:
Users↑
dsquery user -name <known username>
For example:
dsquery user -name A*
Example output:
dsquery user -name A*
"CN=Administrator,CN=Users,DC=hu,DC=ibm,DC=isec,DC=com"
"CN=Alison Greene,CN=Users,DC=hu,DC=ibm,DC=isec,DC=com"
Groups↑
dsquery group -name <known group name>
For example:
dsquery group -name A*
Example output:
dsquery group -name A*
"CN=Administrators,CN=Builtin,DC=hu,DC=ibm,DC=isec,DC=com"
"CN=Access Control Assistance Operators,CN=Builtin,DC=hu,DC=ibm,DC=isec,DC=com"
"CN=Account Operators,CN=Builtin,DC=hu,DC=ibm,DC=isec,DC=com"
"CN=Allowed RODC Password Replication Group,CN=Users,DC=hu,DC=ibm,DC=isec,DC=com"