X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;f=org.argeo.node.api%2Fsrc%2Forg%2Fargeo%2Fnode%2Fsecurity%2FNodeSecurityUtils.java;h=7c784b0dc39f6032840989e94e5f8670c5e57d4b;hb=6a24c2c16747f56956097f0cc05c146c82fa1044;hp=97618d5ecaa11d3cd48e911cdda635fb970d32ab;hpb=7e333073d07b780efe681306a1842a750cbea83c;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.node.api/src/org/argeo/node/security/NodeSecurityUtils.java b/org.argeo.node.api/src/org/argeo/node/security/NodeSecurityUtils.java index 97618d5ec..7c784b0dc 100644 --- a/org.argeo.node.api/src/org/argeo/node/security/NodeSecurityUtils.java +++ b/org.argeo.node.api/src/org/argeo/node/security/NodeSecurityUtils.java @@ -10,11 +10,13 @@ import javax.naming.ldap.LdapName; import org.argeo.node.NodeConstants; public class NodeSecurityUtils { - public final static LdapName ROLE_ADMIN_NAME, ROLE_ANONYMOUS_NAME, ROLE_USER_NAME, ROLE_USER_ADMIN_NAME; + public final static LdapName ROLE_ADMIN_NAME, ROLE_DATA_ADMIN_NAME, ROLE_ANONYMOUS_NAME, ROLE_USER_NAME, + ROLE_USER_ADMIN_NAME; public final static List RESERVED_ROLES; static { try { ROLE_ADMIN_NAME = new LdapName(NodeConstants.ROLE_ADMIN); + ROLE_DATA_ADMIN_NAME = new LdapName(NodeConstants.ROLE_DATA_ADMIN); ROLE_USER_NAME = new LdapName(NodeConstants.ROLE_USER); ROLE_USER_ADMIN_NAME = new LdapName(NodeConstants.ROLE_USER_ADMIN); ROLE_ANONYMOUS_NAME = new LdapName(NodeConstants.ROLE_ANONYMOUS); @@ -31,8 +33,8 @@ public class NodeSecurityUtils { } public static void checkImpliedPrincipalName(LdapName roleName) throws IllegalArgumentException { - if (ROLE_USER_NAME.equals(roleName) || ROLE_ANONYMOUS_NAME.equals(roleName)) - throw new IllegalArgumentException(roleName + " cannot be listed as role"); +// if (ROLE_USER_NAME.equals(roleName) || ROLE_ANONYMOUS_NAME.equals(roleName)) +// throw new IllegalArgumentException(roleName + " cannot be listed as role"); } }