[英]How to authenticate with Active Directory using java in XPages
I need to know if a user entered correct login information to Microsoft Active directory 我需要知道用户是否在Microsoft Active Directory中输入了正确的登录信息
I want the user to enter username and password on an xpage and it should only return if these values was entered correctly or not. 我希望用户在xpage上输入用户名和密码,并且只有在正确输入或未输入这些值的情况下,它才应返回。
I know I can use ldap requests and send in credentials but have not seen any working solutions for this. 我知道我可以使用ldap请求并发送凭据,但是还没有看到任何有效的解决方案。
I need to use java as the code should be able to run on non windows servers 我需要使用Java,因为代码应该能够在非Windows服务器上运行
There are a number of approaches you can take: 您可以采取多种方法:
Let us know which one works for you 让我们知道哪一个适合您
You can use JNDI to access the Active Directory. 您可以使用JNDI访问Active Directory。 There are a lot of ressources on the web on how to do this, for example have a look at http://mhimu.wordpress.com/2009/03/18/active-directory-authentication-using-javajndi/
网上有很多关于如何执行此操作的资源,例如,请访问http://mhimu.wordpress.com/2009/03/18/active-directory-authentication-using-javajndi/
You have tagged the question as XPage, do you want to do the authentication from inside domino? 您已将问题标记为XPage,是否要从多米诺内部进行身份验证? In that case the domino server could do the authentication.
在这种情况下,多米诺服务器可以进行身份验证。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.