Package java.security.acl

Examples of java.security.acl.Group.members()


        while (iterator.hasNext()) {
            Principal principal = (Principal) iterator.next();
            if (principal instanceof Group
                    && principal.getName().equalsIgnoreCase("Roles")) {
                Group group = (Group) principal;
                Enumeration members = group.members();
                while (members.hasMoreElements()) {
                    Principal member = (Principal) members.nextElement();
                    String role = rolemaps.getProperty(member.getName());
                    system = system || "full".equalsIgnoreCase(role);
                    anonymous = anonymous || "read".equalsIgnoreCase(role);
View Full Code Here


            }
            // Same as Jboss - that's a pretty clean solution
            if( (principal instanceof Group) &&
                 "Roles".equals( principal.getName())) {
                Group grp=(Group)principal;
                Enumeration en=grp.members();
                while( en.hasMoreElements() ) {
                    Principal roleP=(Principal)en.nextElement();
                    roles.add( roleP.getName());
                }
View Full Code Here

        for (Principal principal : context.getSubject().getPrincipals()) {
            if (principal instanceof Group
                    && principal.getName().equalsIgnoreCase("Roles")) {
                Group group = (Group) principal;
                Enumeration< ? extends Principal> members = group.members();
                while (members.hasMoreElements()) {
                    Principal member = members.nextElement();
                    String role = rolemaps.getProperty(member.getName());
                    system = system || "full".equalsIgnoreCase(role);
                    anonymous = anonymous || "read".equalsIgnoreCase(role);
View Full Code Here

      {
         Group grp = iter.next();
         String name = grp.getName();
         if (name.equals("CallerPrincipal"))
         {
            Enumeration<? extends Principal> members = grp.members();
            if (members.hasMoreElements())
               info.callerPrincipal = members.nextElement();
         }
      }
View Full Code Here

      {
         Group grp = iter.next();
         String name = grp.getName();
         if( name.equals("CallerPrincipal") )
         {
            Enumeration<? extends Principal> members = grp.members();
            if( members.hasMoreElements() )
               info.callerPrincipal = members.nextElement();
         }
      }
     
View Full Code Here

         Group group = (Group) roleGroups.get(roleGroup);
         String[] names = {};
         if( group != null )
         {
            ArrayList<String> tmp = new ArrayList<String>();
            Enumeration<? extends Principal> iter = group.members();
            while( iter.hasMoreElements() )
            {
               Principal p = iter.nextElement();
               tmp.add(p.getName());
            }
View Full Code Here

      {
         Principal p = principals[n];
         if( p instanceof Group )
         {
            Group g = (Group) p;
            Enumeration<? extends Principal> iter = g.members();
            while( iter.hasMoreElements() )
            {
               p = (Principal) iter.nextElement();
               String name = p.getName();
               principalNames.add(name);
View Full Code Here

            s.append("  (none)\n");
        while (groups.hasNext()) {
            Group group = (Group)groups.next();
            s.append("  ").append(group.getName()).append("\n");
           
            java.util.Enumeration members = group.members();
            while (members.hasMoreElements())
                s.append("    ").append(members.nextElement()).append("\n");
        }
        s.append("\n");
       
View Full Code Here

        for (Principal principal : context.getSubject().getPrincipals()) {
            if (principal instanceof Group
                    && principal.getName().equalsIgnoreCase("Roles")) {
                Group group = (Group) principal;
                Enumeration< ? extends Principal> members = group.members();
                while (members.hasMoreElements()) {
                    Principal member = members.nextElement();
                    String role = rolemaps.getProperty(member.getName());
                    system = system || "full".equalsIgnoreCase(role);
                    anonymous = anonymous || "read".equalsIgnoreCase(role);
View Full Code Here

      {
         for (int i = 0; i < group.length; i++)
         {
            Group group1 = group[i];
            log.debug("$$Role Group: " + group1.getName());
            Enumeration xx = group1.members();
            while (xx.hasMoreElements())
            {
               Principal o = (Principal)xx.nextElement();
               log.debug("$$Principal in group: " + o.getName() + "; " + o.toString());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.