title: Using Active Directory (with LDAP) to authenticate on an angularjs/javascript fronted - what should the flow of the process be?
body: <p>I'm working on a project in which we need to authenticate the user in an application by using his/hers windows credentials. Frontend is using Angularjs and backend java.</p>
  
  <p>After doing a sensible amount of research, I discovered that there is no way on the the frontend to obtain directly the Windows <b>user &amp; pass</b> due to security concerns.</p>
  
  <p>But I'm thinking that the whole process should start here, from the frontend, by obtaining these two encrypted credentials or at least a token and sending them to the backend in order to kickstart the ntlm authentication process.</p>
  
  <p>And also, not sure if the user should have to log in the app by typing his windows credentials or if it should automatically be done with ntlm passthrough.</p>
  
  <p>I do not have a good grip on the concept, and that is because most of the related sources that I found are referring to backend solutions (C# 80% of them), but almost nothing for fronted. So, I humbly require some clarifications on this topic. Is there some sort of middleware or npm package that I should use in order to obtain the user &amp; pass, or what would you advise?</p>