My website is deployed on IIS using an application pool with identity = A.
From this website, can I get the credential of A (full userName and passWord)? Please show me the code also.
string appPoolAccount = System.Security.Principal.WindowsIdentity.GetCurrent().Name;
// Define Context
PrincipalContext context = new PrincipalContext(ContextType.Domain);