Mar 24, 2013 -
Powershell, Scripting, Windows 2003, Windows 2008, Windows 2012
No Comments


How can I search for all users that have the “Network Policy” set to false using PowerShell ?
If you need to search Active Directory to find users who currently have the “Network Access Permission” set to “Deny Access” on the Dial-in tab of their user account
run this Powershell command:
Get-ADUser -Filter {(mail -like “*”) -and (ObjectClass -eq “user”)} -Properties msNPAllowDialin | Where { $_.msNPAllowDialin -match “False” } | fl Name, msNPAllowDialin
You need to ensure you start Powershell with the AD modules installed.
