Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@falbrech-hsdg
Copy link
Contributor

This commit implements a Single Sign On for Mamute which loads all required user information for a trusted SSO user name from LDAP.

We implemented this for use in an Active Directory Environment with Kerberos authentication. To have this working with Mamute, we set up an Apache httpd dealing with Kerberos, setting REMOTE_USER, and forwarding this to an Apache Tomcat. Mamute runs on the Tomcat.

This is not yet tested with Jetty, as I really could not figure out how to easily pass the REMOTE_USER to Jetty WITHOUT using mod_ajp.

To enable SSO, add to your [environment].properties (together with all required LDAP configuration):

ldap.sso = true

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a little confused as to why you need to also check LDAP for the user if the incoming source is trusted. Seems inefficient to me.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, still the user details have to be looked up from LDAP to create the user if needed (e.g. mail address, full name).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, and you'd probably want to keep the users up to date as well. Makes sense.

@falbrech-hsdg
Copy link
Contributor Author

It's open source, isn't it? @monitorjbl could extend my code proposal, if it is not sufficient for him.

If you - as the code maintainer - say you need extensions to this feature to be able to merge it into the master branch, I will see what I can do. But I am not paid by my company to handle random feature requests of third parties, which do not make any sense to us.

For us, our custom-built Mamute works great with this SSO extension (in production for nearly three months now).

@xdarklight
Copy link
Contributor

@falbrech-hsdg thank you for this patchset!
I have successfully tested this by using jetty with AJP connector (with an apache and kerberos authentication in front).

Could you please share the details how you are running mamute on a tomcat?

@falbrech-hsdg
Copy link
Contributor Author

@xdarklight Sorry, it is quite a long time that I supported our Ops team in setting up mamute, and now I do not have access to the server anymore...
What exactly do you want to know? AFAIK, most work is done within the Apache httpd (which you already did successfully). To run mamute on Tomcat, we just extracted the WAR file to webapps/mamute.

According to stackoverflow, you could have to set a flag on Tomcat's AJP connector to enable authentication from the outside:
http://stackoverflow.com/questions/13749065/forward-remote-user-to-tomcat-via-ajp-e-g-for-shibboleth

But I cannot remember if we have set this flag...

@csokol
Copy link
Contributor

csokol commented Jan 17, 2016

Since @falbrech-hsdg and @xdarklight are successfully using this feature, I'm merging :-)

It would be awesome if you guys could provide an integrated test with a running ldap service in the future. (we could setup the ldap service with a docker container, for example)

csokol added a commit that referenced this pull request Jan 17, 2016
Implements LDAP based Single Sign On
@csokol csokol merged commit 6e3c1e8 into caelum:master Jan 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants