Examples of RetrievalMethod


Examples of org.apache.xml.security.keys.content.RetrievalMethod

         xpathC.setXPathNamespaceContext("ds", Constants.SignatureSpecNS);
         xpathC.setXPath("ancestor-or-self::ds:X509Data");
         retrievalTransforms.addTransform(Transforms.TRANSFORM_XPATH,
                                          xpathC.getElement());
         sig.getKeyInfo().add(
            new RetrievalMethod(
               doc, "#object-4", retrievalTransforms,
               "http://www.w3.org/2000/09/xmldsig#X509Data"));

         /*
         X509Data x509data = new X509Data(doc);
View Full Code Here

Examples of org.apache.xml.security.keys.content.RetrievalMethod

         xpathC.setXPathNamespaceContext("ds", Constants.SignatureSpecNS);
         xpathC.setXPath("ancestor-or-self::ds:X509Data");
         retrievalTransforms.addTransform(Transforms.TRANSFORM_XPATH,
                                          xpathC.getElement());
         sig.getKeyInfo().add(
            new RetrievalMethod(
               doc, "#object-4", retrievalTransforms,
               "http://www.w3.org/2000/09/xmldsig#X509Data"));

         /*
         X509Data x509data = new X509Data(doc);
View Full Code Here

Examples of org.apache.xml.security.keys.content.RetrievalMethod

     * @param retrievalmethod
     */
    public void addRetrievalMethod(SOAPElement retrievalmethod)
        throws XWSSecurityException {
        try {
            RetrievalMethod rm = new RetrievalMethod(retrievalmethod, null);
            delegateKeyInfo.add(rm);
            dirty = true;
        } catch(XMLSecurityException e) {
            throw new XWSSecurityException(e);
        }
View Full Code Here

Examples of org.apache.xml.security.keys.content.RetrievalMethod

     * @param uri
     * @param transforms
     * @param Type 
     */
    public void addRetrievalMethod(String uri, Transforms transforms, String Type) {
        this.add(new RetrievalMethod(this.doc, uri, transforms, Type));
    }
View Full Code Here

Examples of org.apache.xml.security.keys.content.RetrievalMethod

        Element e =
            XMLUtils.selectDsNode(
                this.constructionElement.getFirstChild(), Constants._TAG_RETRIEVALMETHOD, i);

        if (e != null) {
            return new RetrievalMethod(e, this.baseURI);
        }
        return null;
    }
View Full Code Here

Examples of org.opensaml.xml.signature.RetrievalMethod

*/
public class RetrievalMethodMarshaller extends AbstractXMLSignatureMarshaller {

    /** {@inheritDoc} */
    protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException {
        RetrievalMethod rm = (RetrievalMethod) xmlObject;

        if (rm.getURI() != null) {
            domElement.setAttributeNS(null, RetrievalMethod.URI_ATTRIB_NAME, rm.getURI());
        }
        if (rm.getType() != null) {
            domElement.setAttributeNS(null, RetrievalMethod.TYPE_ATTRIB_NAME, rm.getType());
        }
    }
View Full Code Here

Examples of org.opensaml.xml.signature.RetrievalMethod

*/
public class RetrievalMethodUnmarshaller extends AbstractXMLSignatureUnmarshaller {

    /** {@inheritDoc} */
    protected void processAttribute(XMLObject xmlObject, Attr attribute) throws UnmarshallingException {
        RetrievalMethod rm = (RetrievalMethod) xmlObject;

        if (attribute.getLocalName().equals(RetrievalMethod.URI_ATTRIB_NAME)) {
            rm.setURI(attribute.getValue());
        } else if (attribute.getLocalName().equals(RetrievalMethod.TYPE_ATTRIB_NAME)) {
            rm.setType(attribute.getValue());
        } else {
            super.processAttribute(xmlObject, attribute);
        }
    }
View Full Code Here

Examples of org.opensaml.xml.signature.RetrievalMethod

    }

    /** {@inheritDoc} */
    protected void processChildElement(XMLObject parentXMLObject, XMLObject childXMLObject)
            throws UnmarshallingException {
        RetrievalMethod rm = (RetrievalMethod) parentXMLObject;

        if (childXMLObject instanceof Transforms) {
            rm.setTransforms((Transforms) childXMLObject);
        } else {
            super.processChildElement(parentXMLObject, childXMLObject);
        }
    }
View Full Code Here

Examples of org.opensaml.xml.signature.RetrievalMethod

     * @param encKey the EncryptedKey
     */
    protected void linkSinglePeerKey(EncryptedData encData, EncryptedKey encKey) {
        log.debug("Linking single peer EncryptedKey with RetrievalMethod and DataReference");
        // Forward reference from EncryptedData to the EncryptedKey
        RetrievalMethod rm = retrievalMethodBuilder.buildObject();
        rm.setURI("#" + encKey.getID());
        rm.setType(EncryptionConstants.TYPE_ENCRYPTED_KEY);
        encData.getKeyInfo().getRetrievalMethods().add(rm);
       
        // Back reference from the EncryptedKey to the EncryptedData
        DataReference dr = dataReferenceBuilder.buildObject();
        dr.setURI("#" + encData.getID());
View Full Code Here

Examples of org.opensaml.xml.signature.RetrievalMethod

*/
public class RetrievalMethodUnmarshaller extends AbstractXMLSignatureUnmarshaller {

    /** {@inheritDoc} */
    protected void processAttribute(XMLObject xmlObject, Attr attribute) throws UnmarshallingException {
        RetrievalMethod rm = (RetrievalMethod) xmlObject;

        if (attribute.getLocalName().equals(RetrievalMethod.URI_ATTRIB_NAME)) {
            rm.setURI(attribute.getValue());
        } else if (attribute.getLocalName().equals(RetrievalMethod.TYPE_ATTRIB_NAME)) {
            rm.setType(attribute.getValue());
        } else {
            super.processAttribute(xmlObject, attribute);
        }
    }
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.