Package org.apache.jetspeed.security.impl

Examples of org.apache.jetspeed.security.impl.RoleImpl


        }
        if (!hasPortalUserRole)
        {
            // add portal user role: used in web.xml authorization to
            // detect authenticated portal users
            roles.addMember(new RoleImpl(portalUserRole));       
        }
        subject.getPrincipals().add(roles);
    }
View Full Code Here


        Set principals = new PrincipalsSet();
        Set publicCredentials = new HashSet();
        Set privateCredentials = new HashSet();
       
        principals.add(new UserImpl("david"));
        principals.add(new RoleImpl("ATP"));
        principals.add(new RoleImpl("NB"));       
        principals.add(new RoleImpl("ATP-NB"));
       
        Subject subject = new Subject(true, principals, publicCredentials, privateCredentials);       
        return subject;
    }
View Full Code Here

        Set principals = new PrincipalsSet();
        Set publicCredentials = new HashSet();
        Set privateCredentials = new HashSet();

        principals.add(new UserImpl("david"));
        principals.add(new RoleImpl("ATP"));
        principals.add(new RoleImpl("NB"));
       
        Subject subject = new Subject(true, principals, publicCredentials, privateCredentials);       
        return subject;
    }
View Full Code Here

                return "someNonJetspeedPrincipal";
            }
           
        });
        // add a Jetspeed role principal ==> should be ignored as well
        s.getPrincipals().add(new RoleImpl("someRole"));
       
        users = ssoManager.getRemoteUsers(testSite,s);
        assertEquals(2,users.size());

        ssoManager.addUser(testSite, testuser, "someRemoteUser", "someRemotePwd");
View Full Code Here

        Set principals = new PrincipalsSet();
        Set publicCredentials = new HashSet();
        Set privateCredentials = new HashSet();
       
        principals.add(new UserImpl("david"));
        principals.add(new RoleImpl("ATP"));
        principals.add(new RoleImpl("NB"));       
        principals.add(new RoleImpl("ATP-NB"));
       
        Subject subject = new Subject(true, principals, publicCredentials, privateCredentials);       
        return subject;
    }
View Full Code Here

        Set principals = new PrincipalsSet();
        Set publicCredentials = new HashSet();
        Set privateCredentials = new HashSet();

        principals.add(new UserImpl("david"));
        principals.add(new RoleImpl("ATP"));
        principals.add(new RoleImpl("NB"));
       
        Subject subject = new Subject(true, principals, publicCredentials, privateCredentials);       
        return subject;
    }
View Full Code Here

   
    public void testSubsiteRules()
    {
        RequestContext request = new MockRequestContext("/");
        Set principals = new PrincipalsSet();
        principals.add(new RoleImpl("role"));
        request.setSubject(JetspeedSubjectFactory.createSubject(new UserImpl("user"), null, null, principals));
        request.setLocale(new Locale("en", "US"));
        MockHttpServletRequest servletRequest = new MockHttpServletRequest();
        servletRequest.setServerName("www.domain.com");
        request.setRequest(servletRequest);
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.security.impl.RoleImpl

Copyright © 2018 www.massapicom. 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.