aspose file tools*
The moose likes JForum and the fly likes SSO and groups management Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Products » JForum
Bookmark "SSO and groups management" Watch "SSO and groups management" New topic
Author

SSO and groups management

Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Hi.

I am using a custom SSO implementation and I would need to assign groups to users (while registering or while logging in), according to my identity repository.

What should I do ?

Yvan

[originally posted on jforum.net by yjanet]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I have just seen in the GenericUserDAO that groups may be added by using


I guess I need to implement my own UserDAO to assign the right groups instead of the default one or do I only need to work only with the SSOUtils and add something like this :


(I mean, which way is cleaner ?)
[originally posted on jforum.net by yjanet]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
A lot depends on your application needs. In general, if you have a small number of fairly static groups that you need to map to jForum groups, then handling it in the SSO implementation is fine. Just use the existing DAO structure to add the user to the matching jForum group.

One thing to think about is if you want the SSO system to validate group membership with each call. E.g., removing people from jForum groups when they are removed from the overall application group.

Take a look at the admin UserAction.groupsSave method for details on how to do this. Note that you will also have to deal with the SecurityRepository, e.g. removing the user so that it is refreshed with the new info.

On the other hand, if you have a large number of dynamic application groups that you need to map into jForum groups, then you probably want to look at writing your own DAO implimentations. This lets you populate the user and group entity objects with info from your main application mixed with jForum tables.

Be warned that this is not for the faint of heart. There are a lot of little "fiddly bits" that need understood and planned for.
[originally posted on jforum.net by monroe]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Thanks a lot.

I think I'm going to do it with the current DAO structure, making this more evolvable.
As I already have my SSO module, I think I just have to enhance it a bit.

Yvan
[originally posted on jforum.net by yjanet]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: SSO and groups management
 
Similar Threads
Uploading the Avatar using SSO
Enabling SSO in J2EE application
SSO, users groups, roles, LDAP, etc.
Urgent help required - Can't get any SSO setups working :o(
Session time out and Logout