title: How to get currently Windows logged User Credentials?
body: <p>I am working on an ASP.NET Core 2.0 web app. It has it's login and own User interface. 
     I am trying to retrieve Windows logged users' credentials - like user name, email and password. On login in app, the logged in user's credentials are set as the User. So I need to retrieve windows logged in user's info before login process. I tried the following :</p>
  
  <pre><code> // If domain is example.com, DomainName gives EXAMPLECOM. Plus can't access Password
   string evnName = Environment.UserDomainName + Environment.UserName;
  </code></pre>
  
  <p>In HomeController (after login) and Startup, I tried</p>
  
  <pre><code>// User is null   
  string userName = this.User.FindFirst(ClaimTypes.Name)?.Value;
  </code></pre>
  
  <p>I tried the above in a Service where login process is processed. Can't get from their too.</p>
  
  <p>The main reason to retrieve this is to identify if the user has privileges for SMTP access or not, if so set SMTP.</p>
  
  <p>Can anyone please help me know, how can I retrieve Windows Logged User's credentials somehow before Login process.</p>
  
  <p>Thanks a lot.</p>