i'm trying to get the username and domain from Windows, using
WindowsIdentity windowsIdentity = WindowsIdentity.GetCurrent();
windowsIdentity.Name;
but its always returning 'IIS APPPOOL\DefaultAppPool'. What could I do to return the correct value?
Thanks