[java-plugin-shibd] branch main updated: Remove SAML keys from base plugin.
Scott Cantor
cantor.2 at osu.edu
Tue Aug 20 14:45:49 UTC 2024
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch main
in repository java-plugin-shibd.
View the commit online:
http://git.shibboleth.net/view/?p=java-plugin-shibd.git;a=commit;h=d1625bc8a9dbca2d550eaaede97b6c957ff9579f
The following commit(s) were added to refs/heads/main by this push:
new d1625bc Remove SAML keys from base plugin.
d1625bc is described below
commit d1625bc8a9dbca2d550eaaede97b6c957ff9579f
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue Aug 20 10:45:45 2024 -0400
Remove SAML keys from base plugin.
---
.../net/shibboleth/idp/module/conf/sp/agents.xml | 6 +--
.../shibboleth/idp/module/conf/sp/credentials.xml | 47 -------------------
.../shibboleth/idp/module/conf/sp/sp.properties | 10 -----
.../net/shibboleth/sp/conf/agents-system.xml | 2 +-
.../sp/flows/AbstractBaseSPFlowTest.java | 40 -----------------
.../sp/flows/ParseRequestMapFlowTest.java | 2 +-
.../java/net/shibboleth/sp/flows/PingFlowTest.java | 2 +-
.../net/shibboleth/sp/flows/SealerFlowTest.java | 2 +-
.../sp/flows/SessionInitiatorFlowTest.java | 2 +-
.../net/shibboleth/sp/flows/StorageFlowTest.java | 2 +-
...SPEnvironmentApplicationContextInitializer.java | 52 ----------------------
.../net/shibboleth/idp/module/conf/sp/agents.xml | 3 --
12 files changed, 8 insertions(+), 162 deletions(-)
diff --git a/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/agents.xml b/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/agents.xml
index d9af034..435193b 100644
--- a/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/agents.xml
+++ b/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/agents.xml
@@ -17,6 +17,8 @@
You can add any number of additional imported files to organize your configuration.
By default, the RelyingParty definitions below are used for all Applications unless overridden.
+
+ This is an "empty" example in that it assumes neither SAML, OpenID, or any other protocols.
-->
<!-- ============ Agents and their Applications ============ -->
@@ -31,10 +33,6 @@
</property>
</bean>
- <!-- Default file for defining keys and certificates. -->
- <import resource="credentials.xml" />
-
-
<!-- ============ RelyingParty defaults ============ -->
<!--
diff --git a/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/credentials.xml b/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/credentials.xml
deleted file mode 100644
index fb1f6e1..0000000
--- a/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/credentials.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:context="http://www.springframework.org/schema/context"
- xmlns:util="http://www.springframework.org/schema/util"
- xmlns:p="http://www.springframework.org/schema/p"
- xmlns:c="http://www.springframework.org/schema/c"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
- http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
- http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd"
-
- default-init-method="initialize"
- default-destroy-method="destroy">
-
- <!--
- This defines the signing and encryption key and certificate pairs referenced by your agent/application
- configuration. You don't normally need to touch this, unless you have advanced requirements such as
- supporting multiple sets of keys for different IdPs, in which case you may want to define all your
- credentials here for convenience and reference them as needed.
- -->
-
- <!-- Your SP's default signing key, set via property file. -->
- <bean id="shibboleth.DefaultSigningCredential" parent="shibboleth.BasicX509CredentialFactoryBean"
- p:privateKeyResource="%{sp.signing.key}"
- p:certificateResource="%{sp.signing.cert}" />
-
- <!-- Your SPs default client TLS credential, by default the same as the default signing credential. -->
- <alias alias="shibboleth.DefaultClientTLSCredential" name="shibboleth.DefaultSigningCredential" />
-
- <!-- Your SP's default encryption (really decryption) keys, set via property file. -->
- <util:list id="shibboleth.DefaultEncryptionCredentials">
- <bean parent="shibboleth.BasicX509CredentialFactoryBean"
- p:privateKeyResource="%{sp.encryption.key}"
- p:certificateResource="%{sp.encryption.cert}" />
-
- <!--
- For key rollover, uncomment and point to your original keypair, and use the one above
- to point to your new keypair. Once metadata has propagated, comment this one out again.
- -->
- <!--
- <bean parent="shibboleth.BasicX509CredentialFactoryBean"
- p:privateKeyResource="%{sp.encryption.key.2}"
- p:certificateResource="%{sp.encryption.cert.2}" />
- -->
- </util:list>
-
-</beans>
diff --git a/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/sp.properties b/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/sp.properties
index 4324c42..d0934c0 100644
--- a/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/sp.properties
+++ b/sp-conf-impl/src/main/resources/net/shibboleth/idp/module/conf/sp/sp.properties
@@ -4,16 +4,6 @@
#sp.service.agents.failFast = false
sp.service.agents.checkInterval = PT5M
-# Settings for SP public/private signing and encryption key(s)
-# During decryption key rollover, point the ".2" properties at a second
-# keypair, uncomment in credentials.xml, then publish it in your metadata.
-sp.signing.key = %{idp.home}/credentials/sp/sp-signing.key
-sp.signing.cert = %{idp.home}/credentials/sp/sp-signing.crt
-sp.encryption.key = %{idp.home}/credentials/sp/sp-encryption.key
-sp.encryption.cert = %{idp.home}/credentials/sp/sp-encryption.crt
-#sp.encryption.key.2 = %{idp.home}/credentials/sp/sp-encryption-old.key
-#sp.encryption.cert.2 = %{idp.home}/credentials/sp/sp-encryption-old.crt
-
# Set to empty value to skip shared secret authentication
#sp.agent.authn.method = basic
# Set false to globally disable cookie-based authentication by agents
diff --git a/sp-conf-impl/src/main/resources/net/shibboleth/sp/conf/agents-system.xml b/sp-conf-impl/src/main/resources/net/shibboleth/sp/conf/agents-system.xml
index 61dba3f..e105b6c 100644
--- a/sp-conf-impl/src/main/resources/net/shibboleth/sp/conf/agents-system.xml
+++ b/sp-conf-impl/src/main/resources/net/shibboleth/sp/conf/agents-system.xml
@@ -48,6 +48,6 @@
p:httpServletResponseSupplier-ref="shibboleth.RemotedHttpServletResponseSupplier" />
<!-- Wildcard import hook for plugins. -->
- <import resource="classpath*:/META-INF/net/shibboleth/sp/service/application/postconfig.xml" />
+ <import resource="classpath*:/META-INF/net/shibboleth/sp/service/agent/postconfig.xml" />
</beans>
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/AbstractBaseSPFlowTest.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/AbstractBaseSPFlowTest.java
deleted file mode 100644
index 8187077..0000000
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/AbstractBaseSPFlowTest.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.sp.flows;
-
-import org.springframework.test.context.ContextConfiguration;
-
-/**
- * Base class for testing SP flows within the primary plugin.
- */
- at ContextConfiguration(
- locations = {
- "classpath*:/META-INF/net.shibboleth.idp/postconfig.xml"
- },
- initializers = {
- TestSPEnvironmentApplicationContextInitializer.class,
- }
- )
-public abstract class AbstractBaseSPFlowTest extends AbstractSPFlowTest {
-
- protected AbstractBaseSPFlowTest(final String id) {
- super(id);
- }
-
- protected AbstractBaseSPFlowTest(final String id, final String endId) {
- super(id, endId);
- }
-
-}
\ No newline at end of file
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/ParseRequestMapFlowTest.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/ParseRequestMapFlowTest.java
index 68b99ad..e3e1c39 100644
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/ParseRequestMapFlowTest.java
+++ b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/ParseRequestMapFlowTest.java
@@ -34,7 +34,7 @@ import net.shibboleth.sp.ddf.DDFSupport;
* Unit test for the SP RequestMap-parsing flow.
*/
@SuppressWarnings("javadoc")
-public class ParseRequestMapFlowTest extends AbstractBaseSPFlowTest {
+public class ParseRequestMapFlowTest extends AbstractSPFlowTest {
/** Flow ID. */
@Nonnull public static final String FLOW_ID = "sp/parse-request-map";
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/PingFlowTest.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/PingFlowTest.java
index 2e45805..0a5627d 100644
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/PingFlowTest.java
+++ b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/PingFlowTest.java
@@ -29,7 +29,7 @@ import net.shibboleth.sp.ddf.DDF;
/**
* Unit test for the SP ping flow and some basic agent authentication checks.
*/
-public class PingFlowTest extends AbstractBaseSPFlowTest {
+public class PingFlowTest extends AbstractSPFlowTest {
/** Flow ID. */
@Nonnull public static final String FLOW_ID = "sp/ping";
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SealerFlowTest.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SealerFlowTest.java
index 3a51dab..abd7078 100644
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SealerFlowTest.java
+++ b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SealerFlowTest.java
@@ -36,7 +36,7 @@ import net.shibboleth.sp.profile.impl.DoSealerOperation;
/**
* Unit test for the SP sealer flow.
*/
-public class SealerFlowTest extends AbstractBaseSPFlowTest {
+public class SealerFlowTest extends AbstractSPFlowTest {
/** Flow ID. */
@Nonnull public static final String FLOW_ID = "sp/sealer";
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SessionInitiatorFlowTest.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SessionInitiatorFlowTest.java
index 98d65bb..1bbf23f 100644
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SessionInitiatorFlowTest.java
+++ b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/SessionInitiatorFlowTest.java
@@ -29,7 +29,7 @@ import net.shibboleth.sp.profile.impl.ResolveApplication;
/**
* Unit test for the SP session-initiator flow (basics only).
*/
-public class SessionInitiatorFlowTest extends AbstractBaseSPFlowTest {
+public class SessionInitiatorFlowTest extends AbstractSPFlowTest {
/** Flow ID. */
@Nonnull public static final String FLOW_ID = "sp/session-initiator";
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/StorageFlowTest.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/StorageFlowTest.java
index be5723d..24938b1 100644
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/StorageFlowTest.java
+++ b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/StorageFlowTest.java
@@ -37,7 +37,7 @@ import net.shibboleth.sp.profile.impl.DoStorageOperation;
/**
* Unit test for the SP sealer flow.
*/
-public class StorageFlowTest extends AbstractBaseSPFlowTest {
+public class StorageFlowTest extends AbstractSPFlowTest {
/** Flow ID. */
@Nonnull public static final String FLOW_ID = "sp/storage";
diff --git a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/TestSPEnvironmentApplicationContextInitializer.java b/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/TestSPEnvironmentApplicationContextInitializer.java
deleted file mode 100644
index 8a022bd..0000000
--- a/sp-conf-impl/src/test/java/net/shibboleth/sp/flows/TestSPEnvironmentApplicationContextInitializer.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.sp.flows;
-
-import javax.annotation.Nonnull;
-
-import org.slf4j.Logger;
-import org.springframework.context.ApplicationContextInitializer;
-import org.springframework.context.ConfigurableApplicationContext;
-import org.springframework.core.Ordered;
-import org.springframework.core.annotation.Order;
-import org.springframework.mock.env.MockPropertySource;
-
-import net.shibboleth.shared.primitive.LoggerFactory;
-
-/**
- * An {@link ApplicationContextInitializer} which prepends properties.
- *
- * <p>This needs to include the original IdP-test-layer properties and has to be
- * set to {@link Ordered#LOWEST_PRECEDENCE} or things blow up.</p>
- */
- at Order(Ordered.LOWEST_PRECEDENCE)
-public class TestSPEnvironmentApplicationContextInitializer
- implements ApplicationContextInitializer<ConfigurableApplicationContext> {
-
- /** Class logger. */
- @Nonnull private final Logger log = LoggerFactory.getLogger(TestSPEnvironmentApplicationContextInitializer.class);
-
- /** {@inheritDoc} */
- @Override public void initialize(@Nonnull final ConfigurableApplicationContext applicationContext) {
- final MockPropertySource mock = new MockPropertySource();
- mock.setProperty("idp.home", "classpath:/net/shibboleth/idp/module");
- mock.setProperty("idp.webflows", "classpath*:/flows");
- mock.setProperty("idp.additionalProperties",
- "/conf/ldap.properties, /conf/saml-nameid.properties, /conf/services.properties, /conf/admin/admin.properties, /conf/authn/authn.properties, /conf/c14n/subject-c14n.properties, /credentials/secrets.properties, /conf/sp/sp.properties");
- applicationContext.getEnvironment().getPropertySources().addFirst(mock);
- log.info("Prepending properties '{}'", mock.getSource());
- }
-
-}
\ No newline at end of file
diff --git a/sp-conf-impl/src/test/resources/net/shibboleth/idp/module/conf/sp/agents.xml b/sp-conf-impl/src/test/resources/net/shibboleth/idp/module/conf/sp/agents.xml
index e914f23..3483e23 100644
--- a/sp-conf-impl/src/test/resources/net/shibboleth/idp/module/conf/sp/agents.xml
+++ b/sp-conf-impl/src/test/resources/net/shibboleth/idp/module/conf/sp/agents.xml
@@ -46,9 +46,6 @@
</property>
</bean>
- <!-- Default file for defining keys and certificates. -->
- <import resource="credentials.xml" />
-
<!-- ============ RelyingParty defaults ============ -->
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list