Search in sources :

Example 1 with ResourceResolverSpi

use of org.apache.xml.security.utils.resolver.ResourceResolverSpi in project santuario-java by apache.

the class IAIKTest method test_transforms_signatures_xPathSignature.

/**
 * Method test_transforms_signatures_xPathSignature
 *
 * @throws Exception
 */
@org.junit.Test
public void test_transforms_signatures_xPathSignature() throws Exception {
    String filename = gregorsDir + "transforms/signatures/xPathSignature.xml";
    ResourceResolverSpi resolver = null;
    boolean followManifests = false;
    boolean verify = false;
    try {
        verify = this.verify(filename, resolver, followManifests);
    } catch (RuntimeException ex) {
        LOG.error("Verification crashed for " + filename);
        throw ex;
    }
    if (!verify) {
        LOG.error("Verification failed for " + filename);
    }
    assertTrue(filename, verify);
}
Also used : ResourceResolverSpi(org.apache.xml.security.utils.resolver.ResourceResolverSpi)

Example 2 with ResourceResolverSpi

use of org.apache.xml.security.utils.resolver.ResourceResolverSpi in project santuario-java by apache.

the class IAIKTest method test_transforms_signatures_c14nSignature.

/**
 * Method test_transforms_signatures_c14nSignature
 *
 * @throws Exception
 */
@org.junit.Test
public void test_transforms_signatures_c14nSignature() throws Exception {
    String filename = gregorsDir + "transforms/signatures/c14nSignature.xml";
    ResourceResolverSpi resolver = null;
    boolean followManifests = false;
    boolean verify = false;
    try {
        verify = this.verify(filename, resolver, followManifests, false);
    } catch (RuntimeException ex) {
        LOG.error("Verification crashed for " + filename);
        throw ex;
    }
    if (!verify) {
        LOG.error("Verification failed for " + filename);
    }
    assertTrue(filename, verify);
}
Also used : ResourceResolverSpi(org.apache.xml.security.utils.resolver.ResourceResolverSpi)

Example 3 with ResourceResolverSpi

use of org.apache.xml.security.utils.resolver.ResourceResolverSpi in project santuario-java by apache.

the class IAIKTest method test_signatureAlgorithms_signatures_rSASignature.

/**
 * Method test_signatureAlgorithms_signatures_rSASignature
 *
 * @throws Exception
 */
@org.junit.Test
public void test_signatureAlgorithms_signatures_rSASignature() throws Exception {
    String filename = gregorsDir + "signatureAlgorithms/signatures/rSASignature.xml";
    ResourceResolverSpi resolver = null;
    boolean followManifests = false;
    boolean verify = false;
    try {
        verify = this.verify(filename, resolver, followManifests);
    } catch (RuntimeException ex) {
        LOG.error("Verification crashed for " + filename);
        throw ex;
    }
    if (!verify) {
        LOG.error("Verification failed for " + filename);
    }
    assertTrue(filename, verify);
}
Also used : ResourceResolverSpi(org.apache.xml.security.utils.resolver.ResourceResolverSpi)

Example 4 with ResourceResolverSpi

use of org.apache.xml.security.utils.resolver.ResourceResolverSpi in project santuario-java by apache.

the class IAIKTest method test_transforms_signatures_envelopedSignatureSignature.

/**
 * Method test_transforms_signatures_envelopedSignatureSignature
 *
 * @throws Exception
 */
@org.junit.Test
public void test_transforms_signatures_envelopedSignatureSignature() throws Exception {
    String filename = gregorsDir + "transforms/signatures/envelopedSignatureSignature.xml";
    ResourceResolverSpi resolver = null;
    boolean followManifests = false;
    boolean verify = false;
    try {
        verify = this.verify(filename, resolver, followManifests);
    } catch (RuntimeException ex) {
        LOG.error("Verification crashed for " + filename);
        throw ex;
    }
    if (!verify) {
        LOG.error("Verification failed for " + filename);
    }
    assertTrue(filename, verify);
}
Also used : ResourceResolverSpi(org.apache.xml.security.utils.resolver.ResourceResolverSpi)

Example 5 with ResourceResolverSpi

use of org.apache.xml.security.utils.resolver.ResourceResolverSpi in project santuario-java by apache.

the class BaltimoreTest method test_fifteen_enveloped_dsa.

/**
 * Method test_fifteen_enveloped_dsa
 *
 * @throws Exception
 */
@org.junit.Test
public void test_fifteen_enveloped_dsa() throws Exception {
    String filename = merlinsDir15 + "signature-enveloped-dsa.xml";
    ResourceResolverSpi resolver = new OfflineResolver();
    boolean followManifests = false;
    boolean verify = false;
    try {
        verify = this.verify(filename, resolver, followManifests);
    } catch (RuntimeException ex) {
        LOG.error("Verification crashed for " + filename);
        throw ex;
    }
    if (!verify) {
        LOG.error("Verification failed for " + filename);
    }
    assertTrue(filename, verify);
}
Also used : ResourceResolverSpi(org.apache.xml.security.utils.resolver.ResourceResolverSpi) OfflineResolver(org.apache.xml.security.test.dom.utils.resolver.OfflineResolver)

Aggregations

ResourceResolverSpi (org.apache.xml.security.utils.resolver.ResourceResolverSpi)39 OfflineResolver (org.apache.xml.security.test.dom.utils.resolver.OfflineResolver)21 XMLSignatureException (org.apache.xml.security.signature.XMLSignatureException)3 File (java.io.File)1 ResolverAnonymous (org.apache.xml.security.utils.resolver.implementations.ResolverAnonymous)1