Test AD authentication with Powershell

A quick tip to test AD auth with Powershell:

$UserName = 'xxxx'
$Password = 'yyyy'

Function Test-ADAuthentication {
    param(
        $username,
        $password)
    
    (New-Object DirectoryServices.DirectoryEntry "",$username,$password).psbase.name -ne $null
}

Test-ADAuthentication -username $UserName -password $password

More articles

Checkmk

Because You want to know whats going on.. I am currently looking into an infrastructure monitoring tool called Checkmk that runs

Read More »