[java-shib-attribute] branch main updated: Migrate HTTP connector tests to EmbeddedJetty class.

Codeberg noreply at shibboleth.net
Mon Jul 13 21:35:13 UTC 2026


This is an automated email from the git hooks/post-receive script.

codeberg pushed a commit to branch main
in repository java-shib-attribute.

View the commit online:
https://codeberg.org/Shibboleth/java-shib-attribute/commit/09465747017b2c74fc9ea0ac5b36ca5abe4309de

The following commit(s) were added to refs/heads/main by this push:
     new 094657470 Migrate HTTP connector tests to EmbeddedJetty class.
094657470 is described below

commit 09465747017b2c74fc9ea0ac5b36ca5abe4309de
Author: Scott Cantor <scott at restingparrotsoftware.com>
AuthorDate: Mon Jul 13 17:34:29 2026 -0400

    Migrate HTTP connector tests to EmbeddedJetty class.
---
 .../dc/http/impl/HTTPDataConnectorTest.java        | 76 ++++++++++++----------
 .../resolver/impl/dc/http/repo-entity.crt          | 39 -----------
 .../dc/http/impl/HTTPDataConnectorParserTest.java  | 57 ++++++++++++----
 .../resolver/spring/dc/http/repo-entity.crt        | 39 -----------
 .../resolver/spring/dc/http/repo-rootCA.crt        | 33 ----------
 .../attribute/resolver/spring/dc/http/test.json    | 10 +++
 6 files changed, 97 insertions(+), 157 deletions(-)

diff --git a/shib-attribute-resolver-impl/src/test/java/net/shibboleth/idp/attribute/resolver/dc/http/impl/HTTPDataConnectorTest.java b/shib-attribute-resolver-impl/src/test/java/net/shibboleth/idp/attribute/resolver/dc/http/impl/HTTPDataConnectorTest.java
index ea70f9799..e748adee0 100644
--- a/shib-attribute-resolver-impl/src/test/java/net/shibboleth/idp/attribute/resolver/dc/http/impl/HTTPDataConnectorTest.java
+++ b/shib-attribute-resolver-impl/src/test/java/net/shibboleth/idp/attribute/resolver/dc/http/impl/HTTPDataConnectorTest.java
@@ -19,11 +19,12 @@ import static org.testng.Assert.assertTrue;
 
 import java.io.IOException;
 import java.io.InputStream;
+import java.net.SocketException;
 import java.net.URISyntaxException;
+import java.net.UnknownHostException;
 import java.security.cert.CertificateException;
 import java.security.cert.X509Certificate;
 import java.util.Map;
-import java.util.Set;
 
 import javax.annotation.Nonnull;
 import javax.script.ScriptException;
@@ -39,15 +40,11 @@ import org.opensaml.security.httpclient.impl.SecurityEnhancedHttpClientSupport;
 import org.opensaml.security.trust.TrustEngine;
 import org.opensaml.security.trust.impl.ExplicitKeyTrustEngine;
 import org.opensaml.security.x509.BasicX509Credential;
-import org.opensaml.security.x509.PKIXValidationInformation;
 import org.opensaml.security.x509.X509Credential;
 import org.opensaml.security.x509.X509Support;
-import org.opensaml.security.x509.impl.BasicPKIXValidationInformation;
-import org.opensaml.security.x509.impl.BasicX509CredentialNameEvaluator;
-import org.opensaml.security.x509.impl.CertPathPKIXTrustEvaluator;
-import org.opensaml.security.x509.impl.PKIXX509CredentialTrustEngine;
-import org.opensaml.security.x509.impl.StaticPKIXValidationInformationResolver;
 import org.springframework.core.io.ClassPathResource;
+import org.testng.annotations.AfterClass;
+import org.testng.annotations.BeforeClass;
 import org.testng.annotations.BeforeMethod;
 import org.testng.annotations.Test;
 
@@ -62,8 +59,9 @@ import net.shibboleth.idp.attribute.resolver.testing.TestSources;
 import net.shibboleth.shared.collection.CollectionSupport;
 import net.shibboleth.shared.component.ComponentInitializationException;
 import net.shibboleth.shared.httpclient.HttpClientBuilder;
+import net.shibboleth.shared.resource.Resource;
 import net.shibboleth.shared.spring.resource.ResourceHelper;
-import net.shibboleth.shared.testing.RepositorySupport;
+import net.shibboleth.shared.testing.EmbeddedJetty;
 import net.shibboleth.shared.testing.VelocityEngine;
 
 /**
@@ -74,14 +72,32 @@ public class HTTPDataConnectorTest {
 
     private static final String TEST_CONNECTOR_NAME = "HTTPConnector";
     
-    private static final String TEST_URL =
-            RepositorySupport.buildHTTPResourceURL("java-shib-attribute",
-                    "shib-attribute-resolver-impl/src/test/resources/net/shibboleth/idp/attribute/resolver/impl/dc/http/test.json", false);
+    private static final String TEST_HTTP_URL = "http://localhost:8080/test.json";
+
+    private static final String TEST_HTTPS_URL = "https://localhost:8443/test.json";
 
     private static final String SCRIPT_PATH = "/net/shibboleth/idp/attribute/resolver/impl/dc/http/";
     
+    private EmbeddedJetty jetty;
     private HTTPDataConnector connector;
     
+    @BeforeClass
+    public void startJetty() throws UnknownHostException, SocketException {
+        jetty = new EmbeddedJetty();
+        final EmbeddedJetty.ResourceHandler handler = new EmbeddedJetty.ResourceHandler(200,
+                ResourceHelper.of(new ClassPathResource("net/shibboleth/idp/attribute/resolver/impl/dc/http/test.json")));
+        handler.setContentType("application/json");
+        jetty.startServer(handler);
+    }
+    
+    @AfterClass
+    public void stopJetty() {
+        if (jetty != null) {
+            jetty.stopServer();
+            jetty = null;
+        }
+    }
+    
     @BeforeMethod public void setUp() throws Exception {
         connector = new HTTPDataConnector();
         connector.setId(TEST_CONNECTOR_NAME);
@@ -96,13 +112,13 @@ public class HTTPDataConnectorTest {
         
         // TODO: this will get the header included but isn't actually being tested/enforced atm.
         params.setPreemptiveBasicAuthMap(
-                CollectionSupport.singletonMap(new HttpHost("http", "git.shibboleth.net", 80),
+                CollectionSupport.singletonMap(new HttpHost("http", "localhost", 8080),
                         new UsernamePasswordCredentials("jdoe", "foo".toCharArray())));
         
         connector.setHttpClientSecurityParameters(params);
         
         final TemplatedURLBuilder builder = new TemplatedURLBuilder();
-        builder.setTemplateText(TEST_URL);
+        builder.setTemplateText(TEST_HTTP_URL);
         builder.setVelocityEngine(VelocityEngine.newVelocityEngine());
         builder.setHttpClientSecurityParameters(params);
         builder.setHeaders(CollectionSupport.singletonMap("Accept", "test/html"));
@@ -146,12 +162,11 @@ public class HTTPDataConnectorTest {
 
         final HttpClientSecurityParameters params = new HttpClientSecurityParameters();
         params.setTLSProtocols(CollectionSupport.singleton("SSLv3"));
-        params.setTLSTrustEngine(buildExplicitKeyTrustEngine("repo-entity.crt"));
+        params.setTLSTrustEngine(buildExplicitKeyTrustEngine(EmbeddedJetty.getServerCertficateResource()));
         connector.setHttpClientSecurityParameters(params);
 
         final TemplatedURLBuilder builder = new TemplatedURLBuilder();
-        builder.setTemplateText(RepositorySupport.buildHTTPSResourceURL("java-shib-attribute",
-                    "shib-attribute-resolver-impl/src/test/resources/net/shibboleth/idp/attribute/resolver/impl/dc/http/test.json"));
+        builder.setTemplateText(TEST_HTTPS_URL);
         builder.setVelocityEngine(VelocityEngine.newVelocityEngine());
         builder.setHttpClientSecurityParameters(params);
         builder.initialize();        
@@ -177,7 +192,7 @@ public class HTTPDataConnectorTest {
     @Test(expectedExceptions=ResolutionException.class) public void testSize()
             throws ComponentInitializationException, ResolutionException, ScriptException, IOException {
         final TemplatedURLBuilder builder = new TemplatedURLBuilder();
-        builder.setTemplateText(TEST_URL);
+        builder.setTemplateText(TEST_HTTP_URL);
         builder.setVelocityEngine(VelocityEngine.newVelocityEngine());
         builder.initialize();
         connector.setExecutableSearchBuilder(builder);
@@ -250,7 +265,7 @@ public class HTTPDataConnectorTest {
     
     @Test public void resolveWithCache() throws ComponentInitializationException, ResolutionException, ScriptException, IOException {
         final TemplatedURLBuilder builder = new TemplatedURLBuilder();
-        builder.setTemplateText(TEST_URL);
+        builder.setTemplateText(TEST_HTTP_URL);
         builder.setVelocityEngine(VelocityEngine.newVelocityEngine());
         builder.initialize();
         connector.setExecutableSearchBuilder(builder);
@@ -387,23 +402,14 @@ public class HTTPDataConnectorTest {
         return certArray;
     }
 
-    public static TrustEngine<? super X509Credential> buildPKIXTrustEngine(String cert, String name, boolean nameCheckEnabled) throws URISyntaxException, CertificateException, IOException {
-        final X509Certificate rootCert = X509Support.decodeCertificate(getCertArray(cert));
-        final PKIXValidationInformation info = new BasicPKIXValidationInformation(CollectionSupport.singletonList(rootCert), null, 5);
-        final Set<String> trustedNames = name != null ? CollectionSupport.singleton(name) : CollectionSupport.emptySet();
-        final StaticPKIXValidationInformationResolver resolver = new StaticPKIXValidationInformationResolver(CollectionSupport.singletonList(info), trustedNames);
-        return new PKIXX509CredentialTrustEngine(resolver,
-                new CertPathPKIXTrustEvaluator(),
-                (nameCheckEnabled ? new BasicX509CredentialNameEvaluator() : null));
-    }
-
-    public static TrustEngine<? super X509Credential> buildExplicitKeyTrustEngine(String cert) throws URISyntaxException, CertificateException, IOException {
-        final X509Certificate entityCert = X509Support.decodeCertificate(getCertArray(cert));
-        assert entityCert != null;
-        final X509Credential entityCredential = new BasicX509Credential(entityCert);
-        return new ExplicitKeyTrustEngine(new StaticCredentialResolver(entityCredential));
-        
-    }
+    public static TrustEngine<? super X509Credential> buildExplicitKeyTrustEngine(@Nonnull final Resource cert)
+            throws URISyntaxException, CertificateException, IOException {
+        try (final InputStream certStream = cert.getInputStream()) {
+            final X509Certificate entityCert = X509Support.decodeCertificate(ByteStreams.toByteArray(certStream));
+            final X509Credential entityCredential = new BasicX509Credential(entityCert);
+            return new ExplicitKeyTrustEngine(new StaticCredentialResolver(entityCredential));
+        }
+    }    
 
     public static LayeredConnectionSocketFactory buildSocketFactory() {
         return buildSocketFactory(true);
diff --git a/shib-attribute-resolver-impl/src/test/resources/net/shibboleth/idp/attribute/resolver/impl/dc/http/repo-entity.crt b/shib-attribute-resolver-impl/src/test/resources/net/shibboleth/idp/attribute/resolver/impl/dc/http/repo-entity.crt
deleted file mode 100644
index b9834258f..000000000
--- a/shib-attribute-resolver-impl/src/test/resources/net/shibboleth/idp/attribute/resolver/impl/dc/http/repo-entity.crt
+++ /dev/null
@@ -1,39 +0,0 @@
-## This is the current *.shibboleth.net wildcard cert, expires Jan 2019.
-
------BEGIN CERTIFICATE-----
-MIIGazCCBFOgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwaTELMAkGA1UEBhMCVVMx
-DTALBgNVBAgMBE9oaW8xHjAcBgNVBAoMFVNoaWJib2xldGggQ29uc29ydGl1bTEr
-MCkGA1UEAwwiU2hpYmJvbGV0aCBQcm9qZWN0IEludGVybWVkaWF0ZSBDQTAeFw0x
-ODEyMTExNTE5NDlaFw0zODEyMDYxNTE5NDlaMFoxCzAJBgNVBAYTAlVTMQ0wCwYD
-VQQIDARPaGlvMR4wHAYDVQQKDBVTaGliYm9sZXRoIENvbnN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R4w
-HAYDVQQKDBVTaGliYm9sZXRoIENvbnNvcnRpdW0xIzAhBgNVBAMMGlNoaWJib2xl
-dGggUHJvamVjdCBUZXN0IENBggIQADAOBgNVHQ8BAf8EBAMCBaAwEwYDVR0lBAww
-CgYIKwYBBQUHAwEwDQYJKoZIhvcNAQELBQADggIBAFZQF7KzKGSPieV2eQWbFt30
-kVZzVe/T5UAvrr8n7mRqMfye4QtHHOVM3MHvZv93AXVUQU4PH9KPGtv7poEtwNWk
-7hNbq74z5x5tSvE0EYYI9UMolDL6il+QR5AgLw7YqgMmPPhtm+crmLg8+uMoQDyU
-uSH8ej4rMrdhL2xKlgvL/rhWycpYu1cFLmeolljOZGqr7ITwWJ06BQsLtt4/cyYj
-WiVldHQRZMGAuHLHlX+ukaEg7Gc/N7o936bS5d7AqXwtmtkXiA8An5q5rhncEK1G
-kwUUQN2y5iyx/nD4B2k1IcgFlu/bM4iXZQtmMUtLptUqRssuxS45ukiweiM9UU8n
-WxyxJMzFTctJJ2f/y4Bg5ggsr4WQU/YhoDaQVYxyjXiBt3oT+7eqsoep9HK9xwbG
-xriLzrlao+K3EcKA3vjKGYh15gpEDUbn0Cr5V74TUSdkHjhG7ocaJ5u9/vCS4+AR
-iU5ge2zN6QcwoZKT8+8XGKeXqVc/3hXeXTn3FyvMitPDZsmg8wUhnb/pq5MyKqUA
-bNse4a7oGAeAUGkLf4Q+eLCLSZmL5udrGXdHIffFYqZVcZS+zVWQ1TRfodTDPkFb
-KTz1mcr4KjLNCtplu4CfFpHwC20uk3hPEslOUd+ugj0+HGNH93L7H0WL1GDQoCPh
-RcdRISVwORcD/dit15zD
------END CERTIFICATE-----
diff --git a/shib-attribute-resolver-spring/src/test/java/net/shibboleth/idp/attribute/resolver/spring/dc/http/impl/HTTPDataConnectorParserTest.java b/shib-attribute-resolver-spring/src/test/java/net/shibboleth/idp/attribute/resolver/spring/dc/http/impl/HTTPDataConnectorParserTest.java
index 3ce3b7406..7c89346d6 100644
--- a/shib-attribute-resolver-spring/src/test/java/net/shibboleth/idp/attribute/resolver/spring/dc/http/impl/HTTPDataConnectorParserTest.java
+++ b/shib-attribute-resolver-spring/src/test/java/net/shibboleth/idp/attribute/resolver/spring/dc/http/impl/HTTPDataConnectorParserTest.java
@@ -18,7 +18,10 @@ import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertNotNull;
 import static org.testng.Assert.assertTrue;
 
+import java.io.FileOutputStream;
 import java.io.IOException;
+import java.nio.file.Files;
+import java.nio.file.Path;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
@@ -31,14 +34,18 @@ import javax.annotation.Nonnull;
 import org.opensaml.security.httpclient.HttpClientSecurityParameters;
 import org.springframework.context.support.GenericApplicationContext;
 import org.springframework.core.env.PropertySource;
+import org.springframework.core.io.ClassPathResource;
 import org.springframework.core.io.ResourceLoader;
 import org.springframework.mock.env.MockPropertySource;
 import org.springframework.test.util.ReflectionTestUtils;
 import org.testng.Assert;
+import org.testng.annotations.AfterClass;
 import org.testng.annotations.AfterMethod;
+import org.testng.annotations.BeforeClass;
 import org.testng.annotations.Test;
 
 import com.google.common.cache.Cache;
+import com.google.common.io.Resources;
 
 import net.shibboleth.idp.attribute.IdPAttribute;
 import net.shibboleth.idp.attribute.StringAttributeValue;
@@ -48,23 +55,51 @@ import net.shibboleth.idp.attribute.resolver.dc.http.impl.HTTPDataConnector;
 import net.shibboleth.idp.attribute.resolver.testing.TestSources;
 import net.shibboleth.shared.collection.CollectionSupport;
 import net.shibboleth.shared.spring.resource.PreferFileSystemResourceLoader;
+import net.shibboleth.shared.spring.resource.ResourceHelper;
 import net.shibboleth.shared.spring.util.ApplicationContextBuilder;
-import net.shibboleth.shared.testing.RepositorySupport;
+import net.shibboleth.shared.testing.EmbeddedJetty;
 
 /** Test for {@link HTTPDataConnectorParser}. */
 @SuppressWarnings("javadoc")
 public class HTTPDataConnectorParserTest {
 
-    @Nonnull private static final String TEST_URL =
-            RepositorySupport.buildHTTPSResourceURL("java-shib-attribute",
-                    "shib-attribute-resolver-impl/src/test/resources/net/shibboleth/idp/attribute/resolver/impl/dc/http/test.json");
+    @Nonnull private static final String TEST_URL = "https://localhost:8443/test.json";
 
     private static final String SCRIPT_PATH = "/net/shibboleth/idp/attribute/resolver/spring/dc/http/";
 
     private static final String CREDS_PATH = "/net/shibboleth/idp/attribute/resolver/spring/dc/http/";
 
     private GenericApplicationContext pendingTeardownContext = null;
+
+    private EmbeddedJetty jetty;
+    private String certPath;
+
+    @BeforeClass
+    public void startJetty() throws IOException {
+        // Copy Jetty keystore from jar classpath to file system for Java system property testing.
+        certPath = System.getProperty("java.io.tmpdir") + System.getProperty("file.separator") + "localhost.pem";
+        try (final FileOutputStream certStream = new FileOutputStream(certPath)) {
+            Resources.copy(EmbeddedJetty.getServerCertficateResource().getURL(), certStream);
+        }
+        
+        jetty = new EmbeddedJetty();
+        
+        final EmbeddedJetty.ResourceHandler handler = new EmbeddedJetty.ResourceHandler(200,
+                ResourceHelper.of(new ClassPathResource("net/shibboleth/idp/attribute/resolver/spring/dc/http/test.json")));
+        handler.setContentType("application/json");
+        jetty.startServer(handler);
+    }
     
+    @AfterClass
+    public void stopJetty() throws IOException {
+        if (jetty != null) {
+            jetty.stopServer();
+            jetty = null;
+        }
+        
+        Files.delete(Path.of(certPath));
+    }
+
     @AfterMethod public void tearDownTestContext() {
         if (null == pendingTeardownContext ) {
             return;
@@ -83,7 +118,7 @@ public class HTTPDataConnectorParserTest {
         final MockPropertySource propSource = singletonPropertySource("serviceURL", TEST_URL);
         propSource.setProperty("scriptPath", (SCRIPT_PATH) + "test.js");
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
-        propSource.setProperty("certificateAuthority", CREDS_PATH + "repo-rootCA.crt");
+        propSource.setProperty("certificateAuthority", certPath);
         
         final HTTPDataConnector connector =
                 getDataConnector(propSource,
@@ -114,7 +149,7 @@ public class HTTPDataConnectorParserTest {
         final MockPropertySource propSource = singletonPropertySource("serviceURL", TEST_URL);
         propSource.setProperty("scriptPath", (SCRIPT_PATH) + "test.js");
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
-        propSource.setProperty("certificateAuthority", CREDS_PATH + "repo-rootCA.crt");
+        propSource.setProperty("certificateAuthority", certPath);
         
         final HTTPDataConnector connector =
                 getDataConnector(propSource,
@@ -176,7 +211,7 @@ public class HTTPDataConnectorParserTest {
         final MockPropertySource propSource = singletonPropertySource("serviceURL", TEST_URL);
         propSource.setProperty("scriptPath", (SCRIPT_PATH) + "testsize.js");
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
-        propSource.setProperty("certificateAuthority", CREDS_PATH + "repo-rootCA.crt");
+        propSource.setProperty("certificateAuthority", certPath);
 
         
         final HTTPDataConnector connector =
@@ -196,7 +231,7 @@ public class HTTPDataConnectorParserTest {
         final MockPropertySource propSource = singletonPropertySource("serviceURL", "https://build.shibboleth.net/test.json");
         propSource.setProperty("scriptPath", (SCRIPT_PATH) + "test.js");
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
-        propSource.setProperty("certificateAuthority", CREDS_PATH + "repo-rootCA.crt");
+        propSource.setProperty("certificateAuthority", certPath);
 
         
         final HTTPDataConnector connector =
@@ -236,7 +271,7 @@ public class HTTPDataConnectorParserTest {
         final MockPropertySource propSource = singletonPropertySource("serviceURL", TEST_URL);
         propSource.setProperty("scriptPath", (SCRIPT_PATH) + "test.js");
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
-        propSource.setProperty("certificate", CREDS_PATH + "repo-entity.crt");
+        propSource.setProperty("certificate", certPath);
         
         final HTTPDataConnector connector =
                 getDataConnector(propSource,
@@ -309,7 +344,7 @@ public class HTTPDataConnectorParserTest {
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
         propSource.setProperty("key", "net/shibboleth/idp/attribute/resolver/spring/dc/http/client.key");
         propSource.setProperty("certificate", "net/shibboleth/idp/attribute/resolver/spring/dc/http/client.crt");
-        propSource.setProperty("certificateAuthority", CREDS_PATH + "repo-rootCA.crt");
+        propSource.setProperty("certificateAuthority", certPath);
 
         
         final HTTPDataConnector connector =
@@ -338,7 +373,7 @@ public class HTTPDataConnectorParserTest {
         final MockPropertySource propSource = singletonPropertySource("serviceURL", TEST_URL);
         propSource.setProperty("scriptPath", (SCRIPT_PATH) + "test.js");
         propSource.setProperty("userAgent", "disguised/1.0.0 hidden/3.4.5");
-        propSource.setProperty("certificateAuthority", CREDS_PATH + "repo-rootCA.crt");
+        propSource.setProperty("certificateAuthority", certPath);
         
         final HTTPDataConnector connector =
                 getDataConnector(propSource,
diff --git a/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/repo-entity.crt b/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/repo-entity.crt
deleted file mode 100644
index b9834258f..000000000
--- a/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/repo-entity.crt
+++ /dev/null
@@ -1,39 +0,0 @@
-## This is the current *.shibboleth.net wildcard cert, expires Jan 2019.
-
------BEGIN CERTIFICATE-----
-MIIGazCCBFOgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwaTELMAkGA1UEBhMCVVMx
-DTALBgNVBAgMBE9oaW8xHjAcBgNVBAoMFVNoaWJib2xldGggQ29uc29ydGl1bTEr
-MCkGA1UEAwwiU2hpYmJvbGV0aCBQcm9qZWN0IEludGVybWVkaWF0ZSBDQTAeFw0x
-ODEyMTExNTE5NDlaFw0zODEyMDYxNTE5NDlaMFoxCzAJBgNVBAYTAlVTMQ0wCwYD
-VQQIDARPaGlvMR4wHAYDVQQKDBVTaGliYm9sZXRoIENvbnNvcnRpdW0xHDAaBgNV
-BAMME3Rlc3Quc2hpYmJvbGV0aC5uZXQwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAw
-ggIKAoICAQDI39TBFEbOkf0Bb2h/qnG4bbJRF5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0lBAww
-CgYIKwYBBQUHAwEwDQYJKoZIhvcNAQELBQADggIBAFZQF7KzKGSPieV2eQWbFt30
-kVZzVe/T5UAvrr8n7mRqMfye4QtHHOVM3MHvZv93AXVUQU4PH9KPGtv7poEtwNWk
-7hNbq74z5x5tSvE0EYYI9UMolDL6il+QR5AgLw7YqgMmPPhtm+crmLg8+uMoQDyU
-uSH8ej4rMrdhL2xKlgvL/rhWycpYu1cFLmeolljOZGqr7ITwWJ06BQsLtt4/cyYj
-WiVldHQRZMGAuHLHlX+ukaEg7Gc/N7o936bS5d7AqXwtmtkXiA8An5q5rhncEK1G
-kwUUQN2y5iyx/nD4B2k1IcgFlu/bM4iXZQtmMUtLptUqRssuxS45ukiweiM9UU8n
-WxyxJMzFTctJJ2f/y4Bg5ggsr4WQU/YhoDaQVYxyjXiBt3oT+7eqsoep9HK9xwbG
-xriLzrlao+K3EcKA3vjKGYh15gpEDUbn0Cr5V74TUSdkHjhG7ocaJ5u9/vCS4+AR
-iU5ge2zN6QcwoZKT8+8XGKeXqVc/3hXeXTn3FyvMitPDZsmg8wUhnb/pq5MyKqUA
-bNse4a7oGAeAUGkLf4Q+eLCLSZmL5udrGXdHIffFYqZVcZS+zVWQ1TRfodTDPkFb
-KTz1mcr4KjLNCtplu4CfFpHwC20uk3hPEslOUd+ugj0+HGNH93L7H0WL1GDQoCPh
-RcdRISVwORcD/dit15zD
------END CERTIFICATE-----
diff --git a/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/repo-rootCA.crt b/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/repo-rootCA.crt
deleted file mode 100644
index 89e896f67..000000000
--- a/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/repo-rootCA.crt
+++ /dev/null
@@ -1,33 +0,0 @@
------BEGIN CERTIFICATE-----
-MIIFqDCCA5CgAwIBAgIJAIEDdQdu3nBaMA0GCSqG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ZC/wID
-AQABo2MwYTAdBgNVHQ4EFgQU6lFKNP6lo4e1TixtvcdR5NVuxfkwHwYDVR0jBBgw
-FoAU6lFKNP6lo4e1TixtvcdR5NVuxfkwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8B
-Af8EBAMCAYYwDQYJKoZIhvcNAQELBQADggIBADt/nRWMaUr396xdtu/UNtzm0dfp
-zyqusqaD09JbqW1mQJ/fH6mZ+yPOYd7h5A47znPe9o0jJlR11GcPvRPTM4IR8aLB
-ogK05TGtWP6sBNR8vld87C5e1hKRwoHDqyLUriK/hpi30zB4B+whW0kty6wqF9lt
-X819emItLgDr1qS6v9iDd9AS4xmpcRxP47YugvlIKBNeiuK+UXhY3lBYg4453Pgn
-Fi78GoOM51oEY1LrCpiXSly4sz25MflM47Cppxh5fAIPoFsqRwmpJ3lETBmLCe6v
-7Shjgc0bEidlAxF8BPoXKvMSkjfBRmmhw6UvJ158NmKWSXV6r6x1ZWG/5N2GKpO4
-1eV7RNV4ojpyc87RJJdpstcFJFVjBzEVZ9EcohG1/UDHITu3e5XPrtgPQZGXKjX5
-EHtO5hDb6xxkblQ6qe1L3Ga+ZfNg1rHIpicYz1yZS5mR0dD1LJrzwyan9s1Ld5IU
-v2YWniDlnFXBFWC+9hRF544aN2M/7Q10J13ZYg7d2YbOnp2XhTV1Ud7T/PN4wxHu
-aTJ+2OEsL2Uy4oQ5bGEfgkG22NVxOpAR5/baAoqwxUxIXmE9ub2jVOPt6AzLeNdr
-RaPULkvHLvGMy+VpAqEIPG1OiROg+tWKRmDhF5PtOTneeHR2yHjjWGO+DDY7sAEu
-JWXY3HAfr1aJ7DVm
------END CERTIFICATE-----
diff --git a/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/test.json b/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/test.json
new file mode 100644
index 000000000..c213568b0
--- /dev/null
+++ b/shib-attribute-resolver-spring/src/test/resources/net/shibboleth/idp/attribute/resolver/spring/dc/http/test.json
@@ -0,0 +1,10 @@
+[
+    {
+    "name" : "foo",
+    "values" : [ "foo1" ]
+    },
+    {
+    "name" : "bar",
+    "values" : [ "bar1", "bar2" ]
+    }
+]

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list