Created
November 11, 2015 17:47
-
-
Save joshbtn/d6bffe7d94a9785aabda to your computer and use it in GitHub Desktop.
Search active directory from powershell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
([adsisearcher]"samaccountname=prefix-*").FindAll().Properties.cn | |
([adsisearcher]"(&(objectcategory=computer)(samaccountname=prefix-*))").FindAll().Properties.cn |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment