Examples of canonicalizeSubtree()


Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

      // so reparse the SignedInfo to be sure   
            try {
                Canonicalizer c14nizer =
                    Canonicalizer.getInstance(c14nMethodURI);

                byte[] c14nizedBytes = c14nizer.canonicalizeSubtree(element);
                javax.xml.parsers.DocumentBuilderFactory dbf =
                    javax.xml.parsers.DocumentBuilderFactory.newInstance();
                dbf.setNamespaceAware(true);
                javax.xml.parsers.DocumentBuilder db = dbf.newDocumentBuilder();       
                Document newdoc =
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

        if (this._c14nizedBytes == null) {
            Canonicalizer c14nizer =
                Canonicalizer.getInstance(this.getCanonicalizationMethodURI());

            this._c14nizedBytes =
                c14nizer.canonicalizeSubtree(this._constructionElement);
        }

        // make defensive copy
        return (byte[]) this._c14nizedBytes.clone();
    }
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                Canonicalizer.getInstance(this.getCanonicalizationMethodURI());
            c14nizer.setWriter(os);
            String inclusiveNamespaces = this.getInclusiveNamespaces();

            if (inclusiveNamespaces == null) {
                c14nizer.canonicalizeSubtree(this._constructionElement);
            } else {
                c14nizer.canonicalizeSubtree
                    (this._constructionElement, inclusiveNamespaces);
            }
        } else {
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

            String inclusiveNamespaces = this.getInclusiveNamespaces();

            if (inclusiveNamespaces == null) {
                c14nizer.canonicalizeSubtree(this._constructionElement);
            } else {
                c14nizer.canonicalizeSubtree
                    (this._constructionElement, inclusiveNamespaces);
            }
        } else {
            try {
    os.write(this._c14nizedBytes);
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                                  + secretKey.length() + " octets)");
      sig.sign(sig.createSecretKey(secretKey.getBytes()));

      Canonicalizer c14n =
         Canonicalizer.getInstance(Canonicalizer.ALGO_ID_C14N_WITH_COMMENTS);
      byte[] full = c14n.canonicalizeSubtree(doc);
      byte[] ref = sig.getSignedInfo().item(0).getTransformsOutput().getBytes();
      byte[][] result = {
         full, ref
      };
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                                  + secretKey.length() + " octets)");
      sig.sign(sig.createSecretKey(secretKey.getBytes()));

      Canonicalizer c14n =
         Canonicalizer.getInstance(Canonicalizer.ALGO_ID_C14N_WITH_COMMENTS);
      byte[] full = c14n.canonicalizeSubtree(doc);
      byte[] ref = sig.getSignedInfo().item(0).getTransformsOutput().getBytes();
      byte[][] result = {
         full, ref
      };
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                                  + secretKey.length() + " octets)");
      sig.sign(sig.createSecretKey(secretKey.getBytes()));

      Canonicalizer c14n =
         Canonicalizer.getInstance(Canonicalizer.ALGO_ID_C14N_WITH_COMMENTS);
      byte[] full = c14n.canonicalizeSubtree(doc);
      byte[] ref = sig.getSignedInfo().item(0).getTransformsOutput().getBytes();
      byte[][] result = {
         full, ref
      };
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                                  + secretKey.length() + " octets)");
      sig.sign(sig.createSecretKey(secretKey.getBytes()));

      Canonicalizer c14n =
         Canonicalizer.getInstance(Canonicalizer.ALGO_ID_C14N_WITH_COMMENTS);
      byte[] full = c14n.canonicalizeSubtree(doc);
      byte[] ref = sig.getSignedInfo().item(0).getTransformsOutput().getBytes();
      byte[][] result = {
         full, ref
      };
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                                  + secretKey.length() + " octets)");
      sig.sign(sig.createSecretKey(secretKey.getBytes()));

      Canonicalizer c14n =
         Canonicalizer.getInstance(Canonicalizer.ALGO_ID_C14N_WITH_COMMENTS);
      byte[] full = c14n.canonicalizeSubtree(doc);
      byte[] ref = sig.getSignedInfo().item(0).getTransformsOutput().getBytes();
      byte[][] result = {
         full, ref
      };
View Full Code Here

Examples of org.apache.xml.security.c14n.Canonicalizer.canonicalizeSubtree()

                                  + secretKey.length() + " octets)");
      sig.sign(sig.createSecretKey(secretKey.getBytes()));

      Canonicalizer c14n =
         Canonicalizer.getInstance(Canonicalizer.ALGO_ID_C14N_WITH_COMMENTS);
      byte[] full = c14n.canonicalizeSubtree(doc);
      byte[] ref = sig.getSignedInfo().item(0).getTransformsOutput().getBytes();
      byte[][] result = {
         full, ref
      };
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.