[security-dev] Group clarification

Marek Posolda mposolda at redhat.com
Thu Feb 7 07:51:50 EST 2013


On 07/02/13 13:20, Pedro Igor Silva wrote:
> I understood your point. Maybe you can use partitions and have something like that:
>
>      - Partition QA (Realm or Tier)  -> Group Management
>
>      - Partition DEV (Realm or Tier) -> Group Management
>
> Or you really need groups with same name ?
yes, it's one of requirements. In portal we are using realms for 
different portal organizations (portal containers). But there is still 
possibility to have groups with same name withing single realm (you 
can't have two children groups called "management" as children of same 
parent group, but you can have two "management" groups if both have 
different parent group).

If I remember correctly, GateIn didn't support this in early stages few 
years ago, but we added it because it was feature request required by 
customers.

Regards,
Marek
>
> Regards.
> Pedro Igor
>
> ----- Original Message -----
> From: "Marek Posolda" <mposolda at redhat.com>
> To: security-dev at lists.jboss.org
> Sent: Thursday, February 7, 2013 10:02:18 AM
> Subject: [security-dev] Group clarification
>
> Hello,
>
> One of the current requirements in GateIn is possibility to have groups
> with same name and with different parents. For example: I can have
> groups "/qa/management" and "/dev/management"
>
> In other words, I have two groups called "management" but both are in
> different parts of group tree, because first one has parent group "qa"
> and second has parent group "dev". Currently Picketlink IDM 3 doesn't
> support it (it always throws exception when it recognize that group with
> same name already exists). Also I am seeing that concept of GroupID
> (path to group from root group - something like "/qa/management") and
> group key has been removed as well even if it was supported in IDM 3.x
> couple of weeks before.
>
> Also for read usecase, there are two methods in IdentityManager to find
> groups:
>
>       Group getGroup(String groupId);
>
>       Group getGroup(String groupName, Group parent);
>
> I think that first one has been designed to find group with argument as
> groupId, so usage could looks like:
>
> Group qaManagersGroup = identityManager.getGroup("/qa/management");
>
> Second one has been designed with usage of plain group names like:
>
> Group qaGroup = identityManager.getGroup("qa", null);
> Group qaManagersGroup = identityManager.getGroup("management", qaGroup);
>
>
> Problem is that currently we are always using first one with groupName
> as an argument (not groupId), so it obviously can't work correctly if we
> have two groups with same name "management" because it's unclear which
> one should be result of finding...:-\
>
>
> Any ideas to address this? My current proposal is:
>
> - Return concept of groupId, which will return the path like
> "/qa/management". So usage could be like:
> Group qaGroup = new SimpleGroup("qa");
> Group qaManagementGroup = new SimpleGroup("management", qaGroup);
> assertEquals("management", qaManagementGroup.getName());
> assertEquals("/qa/management", qaManagement);
>
> - Either
> -- fix all existing usages of identityManager.getGroup(String groupId),
> so it really expects groupId as argument (not groupName):
>
> -- or introduce new method on IdentityManager (and IdentityStore) like:
>
> Group getGroupByGroupId(String groupId);
>
> It's possible that some identityStore implementations doesn't support
> groups with same name (For example current LDAPIdentityStore can't
> support it because there is only one DN for access all groups, but we
> discussed with Pedro that this is planned to address later)
>
> Any thoughts?
> Marek
> _______________________________________________
> security-dev mailing list
> security-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/security-dev



More information about the security-dev mailing list