Вопрос

I have an old grails application (ex. one-app) that has springSecurity for logins. I created a new grails app (two-app) that uses multiple databases (the DB from one-app and a new one). I am deploying both using tomcat

ip.addr.10.10/one-app
ip.addr.10.10/two-app

My question is: I want to have access to both applications by logging in only once. Basically if the user logs in on either application, he would also have access to the other application without logging in again.

Is this possible? Thanks.

Это было полезно?

Решение

Yes, it is possible. You need to use SSO. Currently I use JOSSO for my grails applications (http://www.josso.org) combined with Spring Security.

Другие советы

You can configure RememberMe with exactly same configuration for both apps. After user login into any of application, Spring Security will setup special cookie, that can be reused from other app (mean athorized in another app as well).

See docs for Remember Me - http://grails-plugins.github.com/grails-spring-security-core/docs/manual/guide/9%20Authentication.html#9.3%20Remember-Me%20Cookie

A 3rd option would be to use the same OpenID provider for both applications.

One other approach would be drop Cookies which can be read by both the applications.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top