Examples of handleBSPRule()


Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

        Iterator<ObjectType> objectTypeIterator = signatureType.getObject().iterator();
        while (objectTypeIterator.hasNext()) {
            ObjectType objectType = objectTypeIterator.next();
            ManifestType manifestType = XMLSecurityUtils.getQNameType(objectType.getContent(), WSSConstants.TAG_dsig_Manifest);
            if (manifestType != null) {
                securityContext.handleBSPRule(BSPRule.R5403);
            }
        }

        CanonicalizationMethodType canonicalizationMethodType = signatureType.getSignedInfo().getCanonicalizationMethod();
        if (!WSSConstants.NS_C14N_EXCL.equals(canonicalizationMethodType.getAlgorithm())) {
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

            }
        }

        CanonicalizationMethodType canonicalizationMethodType = signatureType.getSignedInfo().getCanonicalizationMethod();
        if (!WSSConstants.NS_C14N_EXCL.equals(canonicalizationMethodType.getAlgorithm())) {
            securityContext.handleBSPRule(BSPRule.R5404);
        }

        InclusiveNamespaces inclusiveNamespacesType = XMLSecurityUtils.getQNameType(canonicalizationMethodType.getContent(),
                WSSConstants.TAG_c14nExcl_InclusiveNamespaces);
        if (inclusiveNamespacesType != null && inclusiveNamespacesType.getPrefixList().size() == 0) {
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

        }

        InclusiveNamespaces inclusiveNamespacesType = XMLSecurityUtils.getQNameType(canonicalizationMethodType.getContent(),
                WSSConstants.TAG_c14nExcl_InclusiveNamespaces);
        if (inclusiveNamespacesType != null && inclusiveNamespacesType.getPrefixList().size() == 0) {
            securityContext.handleBSPRule(BSPRule.R5406);
        }
    }

    @Override
    protected void addSignatureReferenceInputProcessorToChain(
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

    protected void checkBSPCompliance(InputProcessorChain inputProcessorChain, EncryptedKeyType encryptedKeyType)
            throws XMLSecurityException {
        final WSInboundSecurityContext securityContext = (WSInboundSecurityContext) inputProcessorChain.getSecurityContext();
        if (encryptedKeyType.getType() != null) {
            securityContext.handleBSPRule(BSPRule.R3209);
        }
        if (encryptedKeyType.getMimeType() != null) {
            securityContext.handleBSPRule(BSPRule.R5622);
        }
        if (encryptedKeyType.getEncoding() != null) {
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

        final WSInboundSecurityContext securityContext = (WSInboundSecurityContext) inputProcessorChain.getSecurityContext();
        if (encryptedKeyType.getType() != null) {
            securityContext.handleBSPRule(BSPRule.R3209);
        }
        if (encryptedKeyType.getMimeType() != null) {
            securityContext.handleBSPRule(BSPRule.R5622);
        }
        if (encryptedKeyType.getEncoding() != null) {
            securityContext.handleBSPRule(BSPRule.R5623);
        }
        if (encryptedKeyType.getRecipient() != null) {
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

        }
        if (encryptedKeyType.getMimeType() != null) {
            securityContext.handleBSPRule(BSPRule.R5622);
        }
        if (encryptedKeyType.getEncoding() != null) {
            securityContext.handleBSPRule(BSPRule.R5623);
        }
        if (encryptedKeyType.getRecipient() != null) {
            securityContext.handleBSPRule(BSPRule.R5602);
        }
        EncryptionMethodType encryptionMethodType = encryptedKeyType.getEncryptionMethod();
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

        }
        if (encryptedKeyType.getEncoding() != null) {
            securityContext.handleBSPRule(BSPRule.R5623);
        }
        if (encryptedKeyType.getRecipient() != null) {
            securityContext.handleBSPRule(BSPRule.R5602);
        }
        EncryptionMethodType encryptionMethodType = encryptedKeyType.getEncryptionMethod();
        if (encryptionMethodType == null) {
            securityContext.handleBSPRule(BSPRule.R5603);
        } else {
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

        if (encryptedKeyType.getRecipient() != null) {
            securityContext.handleBSPRule(BSPRule.R5602);
        }
        EncryptionMethodType encryptionMethodType = encryptedKeyType.getEncryptionMethod();
        if (encryptionMethodType == null) {
            securityContext.handleBSPRule(BSPRule.R5603);
        } else {
            String encryptionMethod = encryptionMethodType.getAlgorithm();
            if (!WSSConstants.NS_XENC_RSA15.equals(encryptionMethod)
                && !WSSConstants.NS_XENC_RSAOAEPMGF1P.equals(encryptionMethod)) {
                securityContext.handleBSPRule(BSPRule.R5621);
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

            securityContext.handleBSPRule(BSPRule.R5603);
        } else {
            String encryptionMethod = encryptionMethodType.getAlgorithm();
            if (!WSSConstants.NS_XENC_RSA15.equals(encryptionMethod)
                && !WSSConstants.NS_XENC_RSAOAEPMGF1P.equals(encryptionMethod)) {
                securityContext.handleBSPRule(BSPRule.R5621);
            }
        }
    }

    /*
 
View Full Code Here

Examples of org.apache.wss4j.stax.ext.WSInboundSecurityContext.handleBSPRule()

            || WSSConstants.NS_XMLDSIG_HMACSHA512.equals(algorithm)
            || WSSConstants.NS_XMLDSIG_RSASHA256.equals(algorithm)
            || WSSConstants.NS_XMLDSIG_RSASHA384.equals(algorithm)
            || WSSConstants.NS_XMLDSIG_RSASHA512.equals(algorithm))) {
            // Weakening this rule a bit to allow > SHA-1
            securityContext.handleBSPRule(BSPRule.R5421);
        }

        BigInteger hmacOutputLength = XMLSecurityUtils.getQNameType(
                signatureType.getSignedInfo().getSignatureMethod().getContent(),
                WSSConstants.TAG_dsig_HMACOutputLength);
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.