简体   繁体   English

使用Windows通过JavaScript登录详细信息来自动登录网站吗? 怎么样?

[英]Auto Login in website using windows login details via javascript? How?

I want to write javascript in my application/website so it will auto login my website using windows login details. 我想在我的应用程序/网站中编写javascript,因此它将使用Windows登录详细信息自动登录我的网站。 How can i achieve this using java script? 如何使用Java脚本实现此目的? Browser can be IE or Chrome or Anyother 浏览器可以是IE或Chrome或任何其他浏览器

Javascript codes but unable to fetch password of windows for authentication. Javascript代码,但无法获取Windows密码进行身份验证。 All things tried in only Javascript. 所有事情都只在Javascript中尝试过。

Client-side JavaScript cannot do this (and it would be awful if any website you visited could read the password you use to login to Windows!) 客户端JavaScript无法做到这一点(如果您访问的任何网站都能读取您用于登录Windows的密码,那将是可怕的 !)

Authenticating with Windows login details through a browser is, as far as I know, only possible via NTLM . 据我所知,只能通过NTLM通过浏览器对Windows登录详细信息进行身份验证。

You could write the server-side component of an implementation of NTLM in server-side JavaScript if you wished, but it would be more typical to use an out-of-the-box implementation such as the one built into IIS or this Apache module . 您可以根据需要在服务器端JavaScript中编写NTLM实现的服务器端组件,但是使用开箱即用的实现(例如IIS内置的实现或此Apache模块)更为典型。 。

NTLM may require you to configure your browser to support it. NTLM可能需要您配置浏览器以支持它。

You can not do this with JavaScript alone, you need to do this with some server side solution such as Kerberos in combination with your Active Directory server (or use an older technique such as NTLM). 您不能仅使用JavaScript来做到这一点,您需要结合使用诸如Kerberos之类的服务器端解决方案和您的Active Directory服务器(或使用诸如NTLM之类的较旧技术)来做到这一点。 I'm not sure if there are newer/better ways to achieve this than using Kerberos. 我不确定是否有比使用Kerberos更新/更好的方法。 Any solution will very very likely require configuration in your browser and not all browsers will support all approaches. 任何解决方案很可能都需要在浏览器中进行配置,并且并非所有浏览器都支持所有方法。

Some details can be found here: https://serverfault.com/questions/254813/why-use-kerberos-instead-of-ntlm-in-iis and https://www.roguelynn.com/words/explain-like-im-5-kerberos/ 一些详细信息可以在这里找到: https : //serverfault.com/questions/254813/why-use-kerberos-instead-of-ntlm-in-iishttps://www.roguelynn.com/words/explain-like -im -5-的Kerberos /

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM