FYI,

Active Directory needs:

$userobj = GetObject("LDAP://cn=??,ou=??,etc...")