简体   繁体   English

如何检查用户是否已经登录Windows Active Directory

[英]How can I check if user has alread logged in into Windows Active Directory

I've got a problem and since I am new to login/authentication stuff, I do not have clear vision about where to find the answer. 我遇到了问题,由于我不熟悉登录/身份验证,因此我对在哪里找到答案没有明确的认识。

Here is the issue: 这是问题:

I am going to create webapp ( jsf with primefaces + ejb3 ) which allows users be logged into it without login dialog - which means, that all the auth info, about user's roles, groups etc must be gathered from Active Directory. 我将创建一个webapp(带有primefaces + ejb3的jsf),该应用程序允许用户无需登录对话框即可登录到该应用程序-这意味着必须从Active Directory中收集有关用户角色,组等的所有身份验证信息。 How can I get that ? 我该怎么办? How can I get users info, if user did not provide at least his or her user name ? 如果用户至少没有提供他或她的用户名,我如何获得用户信息? What about I must ask Active Directory domain? 我必须问Active Directory域怎么办?

Can somebody provide if not working one than at least pseudo-code? 如果没有工作,有人可以提供至少伪代码吗?

If you are talking about Windows systems, Microsoft offers two protocols that are able to do SSO (Single Sign On), which is what you are looking for: NTLM and SPNEGO (a variant of Kerberos). 如果您在谈论Windows系统,Microsoft提供了两种能够执行SSO(单点登录)的协议,这就是您要寻找的协议:NTLM和SPNEGO(Kerberos的一种变体)。

The answer to your question depends a bit on the operating system your application will run on. 问题的答案取决于您的应用程序将在其上运行的操作系统。 If that is Windows, then there are a couple of options that use the Windows API to make it a lot easier. 如果是Windows,那么有几个使用Windows API的选项使其变得更加简单。 ( mod-auth-sspi , Waffle ) mod-auth-sspi华夫格

If you are running other systems, you have to use libraries that provide the whole stack like Jespa , modauthkerb or others. 如果您正在运行其他系统,则必须使用提供整个堆栈的库,例如Jespamodauthkerb或其他。

暂无
暂无

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

相关问题 使用Active Directory登录时,如何在Web应用程序(在GWT中)中获得用户登录名? - How can I get user logon name in web application (in GWT) when I logged using Active Directory? 检查在Java应用程序中使用Active Directory登录的用户 - Check for user logged in with Active Directory in Java application 使用Windows上登录的用户在Java中查询Active Directory - Query Active Directory in Java using a logged on user on windows 我可以使用 Active Directory 打开 Windows Enterprise 上用户主目录中的 Java 中的文件吗? - Can I open a file in Java that is in a user's home directory on Windows Enterprise with Active Directory? Android 如何使用共享首选项检查用户登录或注销 - Android how can I check user logged in or logged out using Shared Preferences 如何检查用户已经使用Apache Shiro登录? - How to check that user has already logged in using Apache Shiro? 如何获取已登录用户的 UserID,以便稍后参考? - How can I capture the UserID of the user that has logged in, so I can reference it later? 在删除任何用户之前,如何在CAS中检查当前登录的用户 - How can I check currently logged in user in CAS before deleting any user 如何检查用户是否处于活动状态? - How to check if user is active? 在Spring 3控制器中,如何检查登录用户的权限并有条件地执行某些操作? - In a Spring 3 controller, how can I check the permissions of the logged-in user and do certain actions conditionally?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM