Package com.sun.xml.ws.policy

Examples of com.sun.xml.ws.policy.AssertionSet


                    logger.log(Level.FINE,"NestedPolicy is null");
                }
                populated = true;
                return fitness;
            }
            AssertionSet as = policy.getAssertionSet();
            if(as == null){
                if(logger.getLevel() == Level.FINE){
                    logger.log(Level.FINE," Nested Policy is empty");
                }
                populated = true;
                return fitness;
            }
            Iterator<PolicyAssertion> ast = as.iterator();
           
            while(ast.hasNext()){
                PolicyAssertion assertion = ast.next();
                if(referenceType == null){
                    referenceType = new ArrayList<String>();
View Full Code Here


                    logger.log(Level.FINE,"NestedPolicy is null");
                }
                populated = true;
                return fitness;
            }
            AssertionSet as = policy.getAssertionSet();
            Iterator<PolicyAssertion> paItr = as.iterator();
           
            while(paItr.hasNext()){
                PolicyAssertion assertion  = paItr.next();
                if(PolicyUtil.isRequireDerivedKeys(assertion, spVersion)){
                    rdKey = assertion;
View Full Code Here

       
        NestedPolicy policy = tokenAssertion.getNestedPolicy();
        if(policy==null){
            return;
        }
        AssertionSet as = policy.getAssertionSet();
        Iterator<PolicyAssertion> itr = as.iterator();
        while(itr.hasNext()){
            PolicyAssertion policyAssertion = (PolicyAssertion)itr.next();
            if(policyAssertion.getName().getLocalPart().equals(Constants.WssX509V1Token11)||policyAssertion.getName().getLocalPart().equals(Constants.WssX509V1Token10)){
                x509CB.setValueType(MessageConstants.X509v1_NS);
            }else if(policyAssertion.getName().getLocalPart().equals(Constants.WssX509V3Token10)||policyAssertion.getName().getLocalPart().equals(Constants.WssX509V3Token11)){
View Full Code Here

       
        NestedPolicy policy = tokenAssertion.getNestedPolicy();
        if(policy==null){
            return;
        }
        AssertionSet as = policy.getAssertionSet();
        Iterator<PolicyAssertion> itr = as.iterator();
        while(itr.hasNext()){
            PolicyAssertion policyAssertion = (PolicyAssertion)itr.next();
            if(policyAssertion.getName().getLocalPart().equals(Constants.WssKerberosV5ApReqToken11)){
                kerberosBinding.setValueType(MessageConstants.KERBEROS_V5_APREQ);
            } else if(policyAssertion.getName().getLocalPart().equals(Constants.WssGssKerberosV5ApReqToken11)){
View Full Code Here

    void setTokenValueType(AuthenticationTokenPolicy.UsernameTokenBinding utb, PolicyAssertion tokenAssertion) {
        NestedPolicy policy = tokenAssertion.getNestedPolicy();
        if (policy == null) {
            return;
        }
        AssertionSet as = policy.getAssertionSet();
        Iterator<PolicyAssertion> itr = as.iterator();
        while (itr.hasNext()) {
            PolicyAssertion policyAssertion = (PolicyAssertion) itr.next();
            if (policyAssertion.getName().getLocalPart().equals(Constants.WssUsernameToken10) || policyAssertion.getName().getLocalPart().equals(Constants.WssUsernameToken11)) {
                utb.setValueType(MessageConstants.USERNAME_TOKEN_NS);
            } else if (policyAssertion.getName().getLocalPart().equals(Constants.WssUsernameToken10) || policyAssertion.getName().getLocalPart().equals(Constants.WssUsernameToken11)) {
View Full Code Here

       
    }

    private void parseAssertions(SecureConversationToken scToken, PolicyAssertion localToken){

        final AssertionSet assertions = scToken.getBootstrapPolicy().getAssertionSet();
        for(PolicyAssertion policyAssertion : assertions){
            SecurityPolicyVersion spVersion  =
                    PolicyUtil.getSecurityPolicyVersion(policyAssertion.getName().getNamespaceURI());
            if(PolicyUtil.isTrust13(policyAssertion, spVersion)){
                this.trust13 = (Trust13)policyAssertion;
View Full Code Here

                    logger.log(Level.FINE,"NestedPolicy is null");
                }
                populated = true;
                return fitness;
            }
            AssertionSet assertionSet = policy.getAssertionSet();
            for(PolicyAssertion assertion: assertionSet){
               if(PolicyUtil.isRequireClientCertificate(assertion, spVersion)){
                   requireCC = true;
               } else if(PolicyUtil.isHttpBasicAuthentication(assertion, spVersion)){
                   httpBasicAuthentication = true;
View Full Code Here

                    logger.log(Level.FINE,"NestedPolicy is null");
                }
                populated = true;
                return fitness;
            }
            AssertionSet as = policy.getAssertionSet();
            for(PolicyAssertion pa:as){
                if(PolicyUtil.isWSS10PolicyContent(pa, spVersion)){
                    addRequiredProperty(pa.getName().getLocalPart().intern());
                }else{
                    if(!pa.isOptional()){
View Full Code Here

                    logger.log(Level.FINE,"NestedPolicy is null");
                }
                populated = true;
                return fitness;
            }
            AssertionSet as = policy.getAssertionSet();
            Iterator<PolicyAssertion> paItr = as.iterator();
            while(paItr.hasNext()){
                PolicyAssertion assertion = paItr.next();
                if(PolicyUtil.isBootstrapPolicy(assertion, spVersion)){
                    bootstrapPolicy = assertion.getNestedPolicy();
                }else if(PolicyUtil.isRequireDerivedKeys(assertion, spVersion)){
View Full Code Here

        try{
            ByteArrayOutputStream baos = new ByteArrayOutputStream();
            XMLOutputFactory xof = XMLOutputFactory.newInstance();
            XMLStreamWriter writer = xof.createXMLStreamWriter(baos);
                          
            AssertionSet set = AssertionSet.createAssertionSet(Arrays.asList(new PolicyAssertion[] {token}));
            Policy policy = Policy.createPolicy(Arrays.asList(new AssertionSet[] { set }));
            PolicySourceModel sourceModel = ModelGenerator.getGenerator().translate(policy);
            PolicyModelMarshaller pm = PolicyModelMarshaller.getXmlMarshaller(true);
            pm.marshal(sourceModel, writer);
            writer.close();
View Full Code Here

TOP

Related Classes of com.sun.xml.ws.policy.AssertionSet

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.