-
Notifications
You must be signed in to change notification settings - Fork 0
Home
In todays web projects, it is very likely that you will have more than one application that is responsible for your business. Of course, you want your customers only to signup once and then be able to use all your services without logging in all the time, because this would be quite annoying and most definitly not very helpful in order to achieve a good site conversion.
Although there are a few solutions, that provide this functionality, I was not very happy with what I have seen so far because:
- the solution was too big and provided more features than I actually needed e.g. authentication via Shibboleth, Kerberos etc. but therefore also needed more server power
- the solution mixed authentication and authorization which I did not want. I want every application to decide for itself what a user is allowed to do. One solution I examined preferred to have one central authorization store which is some sort of coupling again.
The goal of the project:
- a small and stateless application that can be scaled as needed
- simple user authentication, no authorization
- the same user base for multiple applications and domains
- easy integration into existing application environments, ideally by customizing/implementing the persistence for that environment
- a solution based on industry standards (no proprietary solution)
Since Cognitor is a multi module Maven project, you need to install the modules into your local Maven repository in order to resolve them later in the build process. This can be done by typing
checkout_dir$ mvn install
Now you can build and start the server by typing
checkout_dir/server$ mvn jetty:run
in the server directory. This will start the server application that will be available on port 8080.
There is also a sample consumer available to demonstrate the basic workflow. There are two maven profiles defined, so you can start two consumers on two different ports in order to see that you only need to login once and are automatically logged in on the other client as well. Go to the sampleConsumer directory and type:
checkout_dir/sampleConsumer$ mvn -Pclient1 jetty:run
and
checkout_dir/sampleConsumer$ mvn -Pclient2 jetty:run
This will start the client applications on ports 9090 and 9595. The client has a prefilled textbox for the openid handle. For the example on localhost you can use the default value. You should get to the main application by clicking on the login button. There you can create and account and login. If you then click the login button on the second client you should directly receive a positive authentication response without provinding the credentials again.
For more details, how the single sign on works, read here
For information how to integrate Cognitor with existing data sources read [this document] (wiki/Integrating-existing-data-sources)