Windows Authentication (ASP.NET)

微笑、不失礼 提交于 2019-12-13 08:05:27

问题


How i can implement Windows Authentication to authenticate user while logging in? I do not want to get a pop up window rather i would like to let my login page(LoginPage.aspx) do the same. Please provide me with the steps/ code(vb.net). Thanks


回答1:


It requires a good amount of code to access active directory and authenticate.Please refer the article on codeproject.com or msdn articles.




回答2:


Maybe you could use this tag in your web.config

<authentication mode="Forms">
    <forms loginUrl="login.aspx" defaultUrl="Login.aspx" timeout="60"></forms>
</authentication>

And in your login.aspx you would write code to access Active Directory.




回答3:


You are missing the point about what windows authentication is. Forms authentication can be used when not part of a domain or there is some specific requirement that windows authentication cannot solve. If a computer is registered in an active directory domain, authentication with the web site will be transparent based on the credentials that were used to login to the domain, eliminating the need to supply credentials each time the application is accessed.



来源:https://stackoverflow.com/questions/13632706/windows-authentication-asp-net

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!