aspose file tools*
The moose likes Servlets and the fly likes Transparent authentication with LDAP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Transparent authentication with LDAP" Watch "Transparent authentication with LDAP" New topic
Author

Transparent authentication with LDAP

Hikari Shidou
Ranch Hand

Joined: Jan 22, 2013
Posts: 88
Hello guys.

We have Windows Active Directory, where all users are registered and use to login in Windows.

We have an Apache server configured to use LDAP to authenticate users in that Active Directory. It's setup so that, in PHP, all we have to do is call . Browser verifies user login in Windows and sends this data to Apache, which talks to LDAP to verify authentication. When LDAP authenticates, that code returns user's login, otherwise it returns null.

This way we can safely and easily authenticate users inside PHP and use their AD login to control access to our softwares. Another advantage is that we don't need a login page and not even have to handle passwords in variables: authentication is handled transparently to users and they are automatically logged to our softwares all the time, and their password never comes into our code.



I'd like to do the same thing with Servlet. I see no reason for it not happen if it works with PHP. But I can't find how to do it. I googled but couldn't find anything. Has anybody done something like that and could point me a way?

Standard authentication with login and password is working in Java. If I have domain, login and password, (that in Servlet would come from a login page) I can authenticate any user.
Ivan Jozsef Balazs
Rancher

Joined: May 22, 2012
Posts: 867
    
    5
Did you check the documentation of your servlet engine?
Hikari Shidou
Ranch Hand

Joined: Jan 22, 2013
Posts: 88
I'm using tomcat. I googled about it, I suppose Google searched on its documentation too lol.
Ivan Jozsef Balazs
Rancher

Joined: May 22, 2012
Posts: 867
    
    5
Good old Google found this
Hikari Shidou
Ranch Hand

Joined: Jan 22, 2013
Posts: 88
Cool! gonna take a look on it, tnx!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Transparent authentication with LDAP