Context: Excel addin needs to test whether the current windows user is a valid active directory user (and determines other permission-based logic based on this)
I set up the Active Directory Membership Provider. With the System.Security.Principal.WindowsIdentity user, I take out the domain name (user account name is \) and then use the username to test against the sAMAccountName in Active Directory (Membership.GetUser()).
Is this a valid way to test whether the current user is logged into active directory?
I get the impression I'm only testing whether the current user account name exists in active directory without actually knowing if the current user is actually logged into active directory.
Then again, I'm not sure what 'logged into active directory' means... I'm pretty new to active directory!