Package org.apache.neethi

Examples of org.apache.neethi.Policy.normalize()


            if (outMessage != null) {
                PolicyInclude policyInclude = outMessage.getPolicyInclude();
                Policy policy = policyInclude.getPolicy();

                if (policy != null) {
                    policy = (Policy) policy.normalize(policyInclude.getPolicyRegistry(), false);

                    try {
                        String policyString = PolicyUtil.policyComponentToString(policy);
                        policyString = PolicyUtil.getSafeString(policyString);
View Full Code Here


            } else if (SPConstants.CLAIMS.equals(ln)) {
                issuedToken.setClaims(child);
            } else if (org.apache.neethi.Constants.ELEM_POLICY.equals(ln)) {
                foundPolicy = true;
                Policy policy = builder.getPolicy(child);
                policy = policy.normalize(builder.getPolicyRegistry(), false);
                issuedToken.setPolicy(child);

                for (Iterator<List<Assertion>> iterator = policy.getAlternatives(); iterator.hasNext();) {
                    processAlternative(iterator.next(), issuedToken);
                    break; // since there should be only one alternative ..
View Full Code Here

                x509Token.setExplicitDerivedKeys(true);
            }
        }

        Policy policy = builder.getPolicy(DOMUtils.getFirstElement(element));
        policy = policy.normalize(builder.getPolicyRegistry(), false);

        for (Iterator<List<Assertion>> iterator = policy.getAlternatives(); iterator.hasNext();) {
            processAlternative(iterator.next(), x509Token, consts);

            /*
 
View Full Code Here

    public void configureOperationPolices(AxisOperation op) throws AxisFault {
        PolicyInclude policyInclude = op.getPolicyInclude();
        Policy policy = policyInclude.getEffectivePolicy();
        if (policy != null) {

            policy = (Policy) policy.normalize(policyInclude
                    .getPolicyRegistry(), false);

            for (Iterator iterator = policy.getAlternatives(); iterator
                    .hasNext();) {
View Full Code Here

                                                               org.apache.neethi.Constants.Q_ELEM_POLICY);

        if (policyElement != null) {

            Policy policy = builder.getPolicy(policyElement);
            policy = (Policy)policy.normalize(false);

            for (Iterator iterator = policy.getAlternatives(); iterator.hasNext();) {
                processAlternative((List)iterator.next(), issuedToken);
                break; // since there should be only one alternative ..
            }
View Full Code Here

                x509Token.setExplicitDerivedKeys(true);
            }


            Policy policy = builder.getPolicy(DOMUtils.getFirstElement(element));
            policy = (Policy)policy.normalize(false);

            for (Iterator iterator = policy.getAlternatives(); iterator.hasNext();) {
                processAlternative((List)iterator.next(), x509Token, consts);

                /*
 
View Full Code Here

        }
        if (getLayout() != null) {
            all.addPolicyComponent(getLayout());
        }
        ea.addPolicyComponent(all);
        PolicyComponent pc = p.normalize(builder.getPolicyRegistry(), true);
        if (pc instanceof Policy) {
            return (Policy)pc;
        } else {
            p = new Policy();
            p.addPolicyComponent(pc);
View Full Code Here

            all.addPolicyComponent(getLayout());
        }

       
        ea.addPolicyComponent(all);
        PolicyComponent pc = p.normalize(builder.getPolicyRegistry(), true);
        if (pc instanceof Policy) {
            return (Policy)pc;
        } else {
            p = new Policy();
            p.addPolicyComponent(pc);
View Full Code Here

        }
        if (getLayout() != null) {
            all.addPolicyComponent(getLayout());
        }
        ea.addPolicyComponent(all);
        PolicyComponent pc = p.normalize(builder.getPolicyRegistry(), true);
        if (pc instanceof Policy) {
            return (Policy)pc;
        } else {
            p = new Policy();
            p.addPolicyComponent(pc);
View Full Code Here

                                                  SP11Constants.INSTANCE,
                                                  builder);
        }

        Policy policy = builder.getPolicy(DOMUtils.getFirstElement(element));
        policy = policy.normalize(builder.getPolicyRegistry(), false);

        for (Iterator<List<Assertion>> iterator = policy.getAlternatives(); iterator.hasNext();) {
            processAlternative(iterator.next(), supportingToken);
            /*
             * for the moment we will say there should be only one alternative
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.