diff options
author | Thomas Lenz <tlenz@iaik.tugraz.at> | 2014-05-13 13:59:50 +0200 |
---|---|---|
committer | Thomas Lenz <tlenz@iaik.tugraz.at> | 2014-05-13 13:59:50 +0200 |
commit | ccdffe119df6380878625267810f5e9efe709de9 (patch) | |
tree | bc0027f4b6801d6d454c62af1f8728e9ef000c48 /id/server/stork2-saml-engine/src/main | |
parent | 1669fdbe08f1672a2b021b51b2522c933742fbf0 (diff) | |
download | moa-id-spss-ccdffe119df6380878625267810f5e9efe709de9.tar.gz moa-id-spss-ccdffe119df6380878625267810f5e9efe709de9.tar.bz2 moa-id-spss-ccdffe119df6380878625267810f5e9efe709de9.zip |
Remove bouncycastle provider
Diffstat (limited to 'id/server/stork2-saml-engine/src/main')
2 files changed, 35 insertions, 36 deletions
diff --git a/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java index 6d9ac9ce3..06e80dc14 100644 --- a/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java +++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java @@ -41,7 +41,6 @@ import eu.stork.peps.auth.engine.X509PrincipalUtil; import org.apache.commons.io.IOUtils; import org.apache.commons.lang.NotImplementedException; import org.bouncycastle.jce.X509Principal; -import org.bouncycastle.jce.provider.BouncyCastleProvider; import org.opensaml.Configuration; import org.opensaml.common.SAMLObject; import org.opensaml.common.SignableSAMLObject; @@ -518,23 +517,23 @@ public final class SignP12 implements SAMLEngineSignI { FileInputStream fisTrustStore = null; try { - // Dynamically register Bouncy Castle provider. - boolean found = false; - // Check if BouncyCastle is already registered as a provider - final Provider[] providers = Security.getProviders(); - for (int i = 0; i < providers.length; i++) { - if (providers[i].getName().equals( - BouncyCastleProvider.PROVIDER_NAME)) { - found = true; - } - } - - // Register only if the provider has not been previously registered - if (!found) { - LOG.debug("SAMLCore: Register Bouncy Castle provider."); - Security.insertProviderAt(new BouncyCastleProvider(), Security - .getProviders().length); - } +// // Dynamically register Bouncy Castle provider. +// boolean found = false; +// // Check if BouncyCastle is already registered as a provider +// final Provider[] providers = Security.getProviders(); +// for (int i = 0; i < providers.length; i++) { +// if (providers[i].getName().equals( +// BouncyCastleProvider.PROVIDER_NAME)) { +// found = true; +// } +// } +// +// // Register only if the provider has not been previously registered +// if (!found) { +// LOG.debug("SAMLCore: Register Bouncy Castle provider."); +// Security.insertProviderAt(new BouncyCastleProvider(), Security +// .getProviders().length); +// } p12Store = KeyStore.getInstance(properties .getProperty("keystoreType")); diff --git a/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java index e31688069..39be750cd 100644 --- a/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java +++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java @@ -22,7 +22,7 @@ import eu.stork.peps.exceptions.SAMLEngineException; import org.apache.commons.io.IOUtils; import org.apache.commons.lang.NotImplementedException; import org.bouncycastle.jce.X509Principal; -import org.bouncycastle.jce.provider.BouncyCastleProvider; +//import org.bouncycastle.jce.provider.BouncyCastleProvider; import org.opensaml.Configuration; import org.opensaml.common.SAMLObject; import org.opensaml.common.SignableSAMLObject; @@ -488,23 +488,23 @@ public class SignSW implements SAMLEngineSignI { LOG.info("Load Cryptographic Service Provider"); FileInputStream fis = null; try { - // Dynamically register Bouncy Castle provider. - boolean found = false; - // Check if BouncyCastle is already registered as a provider - final Provider[] providers = Security.getProviders(); - for (int i = 0; i < providers.length; i++) { - if (providers[i].getName().equals( - BouncyCastleProvider.PROVIDER_NAME)) { - found = true; - } - } - - // Register only if the provider has not been previously registered - if (!found) { - LOG.info("SAMLCore: Register Bouncy Castle provider."); - Security.insertProviderAt(new BouncyCastleProvider(), Security - .getProviders().length); - } +// // Dynamically register Bouncy Castle provider. +// boolean found = false; +// // Check if BouncyCastle is already registered as a provider +// final Provider[] providers = Security.getProviders(); +// for (int i = 0; i < providers.length; i++) { +// if (providers[i].getName().equals( +// BouncyCastleProvider.PROVIDER_NAME)) { +// found = true; +// } +// } +// +// // Register only if the provider has not been previously registered +// if (!found) { +// LOG.info("SAMLCore: Register Bouncy Castle provider."); +// Security.insertProviderAt(new BouncyCastleProvider(), Security +// .getProviders().length); +// } storkOwnKeyStore = KeyStore.getInstance(properties .getProperty(KEYSTORE_TYPE)); |