aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--connector/src/main/java/at/asitplus/eidas/specific/connector/controller/MonitoringController.java2
-rw-r--r--connector/src/main/java/at/asitplus/eidas/specific/connector/provider/PvpMetadataProvider.java33
-rw-r--r--connector_lib/pom.xml4
-rw-r--r--connector_lib/src/main/java/at/asitplus/eidas/specific/connector/gui/GuiBuilderConfigurationFactory.java10
-rw-r--r--eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java4
-rw-r--r--eidas_modules/authmodule-eIDAS-v2/src/test/resources/SpringTest-context_basic_test.xml23
-rw-r--r--pom.xml39
7 files changed, 63 insertions, 52 deletions
diff --git a/connector/src/main/java/at/asitplus/eidas/specific/connector/controller/MonitoringController.java b/connector/src/main/java/at/asitplus/eidas/specific/connector/controller/MonitoringController.java
index 633559de..aa45c836 100644
--- a/connector/src/main/java/at/asitplus/eidas/specific/connector/controller/MonitoringController.java
+++ b/connector/src/main/java/at/asitplus/eidas/specific/connector/controller/MonitoringController.java
@@ -48,8 +48,8 @@ import at.gv.egiz.eaaf.core.api.data.EaafConstants;
import at.gv.egiz.eaaf.core.api.idp.IConfigurationWithSP;
import at.gv.egiz.eaaf.core.api.storage.ITransactionStorage;
import at.gv.egiz.eaaf.core.exceptions.EaafException;
+import at.gv.egiz.eaaf.core.impl.http.IHttpClientFactory;
import at.gv.egiz.eaaf.core.impl.utils.DomUtils;
-import at.gv.egiz.eaaf.core.impl.utils.IHttpClientFactory;
import at.gv.egiz.eaaf.core.impl.utils.Random;
import at.gv.egiz.eaaf.modules.pvp2.api.metadata.IPvpMetadataBuilderConfiguration;
import at.gv.egiz.eaaf.modules.pvp2.api.metadata.IPvpMetadataConfigurationFactory;
diff --git a/connector/src/main/java/at/asitplus/eidas/specific/connector/provider/PvpMetadataProvider.java b/connector/src/main/java/at/asitplus/eidas/specific/connector/provider/PvpMetadataProvider.java
index 43f1740f..651b7b78 100644
--- a/connector/src/main/java/at/asitplus/eidas/specific/connector/provider/PvpMetadataProvider.java
+++ b/connector/src/main/java/at/asitplus/eidas/specific/connector/provider/PvpMetadataProvider.java
@@ -25,10 +25,8 @@ package at.asitplus.eidas.specific.connector.provider;
import java.io.IOException;
import java.security.KeyStore;
-import java.security.KeyStoreException;
import java.security.Provider;
import java.security.cert.CertificateException;
-import java.security.cert.X509Certificate;
import java.text.MessageFormat;
import java.util.ArrayList;
import java.util.Collections;
@@ -38,7 +36,6 @@ import org.apache.commons.lang3.StringUtils;
import org.opensaml.saml.metadata.resolver.MetadataResolver;
import org.opensaml.saml.metadata.resolver.filter.MetadataFilter;
import org.opensaml.saml.metadata.resolver.filter.MetadataFilterChain;
-import org.opensaml.security.x509.BasicX509Credential;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
@@ -50,11 +47,10 @@ import at.gv.egiz.eaaf.core.api.idp.ISpConfiguration;
import at.gv.egiz.eaaf.core.exceptions.EaafConfigurationException;
import at.gv.egiz.eaaf.core.exceptions.EaafException;
import at.gv.egiz.eaaf.core.impl.credential.EaafKeyStoreFactory;
-import at.gv.egiz.eaaf.core.impl.credential.EaafKeyStoreUtils;
import at.gv.egiz.eaaf.core.impl.credential.KeyStoreConfiguration;
import at.gv.egiz.eaaf.core.impl.credential.KeyStoreConfiguration.KeyStoreType;
import at.gv.egiz.eaaf.core.impl.data.Pair;
-import at.gv.egiz.eaaf.core.impl.utils.IHttpClientFactory;
+import at.gv.egiz.eaaf.core.impl.http.IHttpClientFactory;
import at.gv.egiz.eaaf.modules.pvp2.exception.Pvp2MetadataException;
import at.gv.egiz.eaaf.modules.pvp2.impl.metadata.AbstractChainingMetadataProvider;
import at.gv.egiz.eaaf.modules.pvp2.impl.metadata.PvpMetadataResolverFactory;
@@ -131,7 +127,7 @@ public class PvpMetadataProvider extends AbstractChainingMetadataProvider {
final List<MetadataFilter> filterList = new ArrayList<>();
filterList.add(new SchemaValidationFilter(true));
filterList.add(new SimpleMetadataSignatureVerificationFilter(
- getTrustedCertificates(keyStore.getFirst()), entityId));
+ keyStore.getFirst(), entityId));
filterList.add(new PvpEntityCategoryFilter(
basicConfig.getBasicConfigurationBoolean(MsEidasNodeConstants.PROP_CONFIG_PVP_ENABLE_ENTITYCATEGORIES,
true)));
@@ -177,29 +173,4 @@ public class PvpMetadataProvider extends AbstractChainingMetadataProvider {
return "Service-provider chainging metadata provider";
}
-
- private List<BasicX509Credential> getTrustedCertificates(KeyStore trustStore) throws EaafConfigurationException {
- try {
- final List<X509Certificate> certs =
- EaafKeyStoreUtils.readCertsFromKeyStore(trustStore);
- if (certs.isEmpty()) {
- log.warn("No trusted metadata-signing certificates in configuration");
- throw new EaafConfigurationException("module.eidasauth.02",
- new Object[] { "No trusted metadata-signing certificates" });
-
- }
-
- final List<BasicX509Credential> result = new ArrayList<>();
- for (final X509Certificate cert : certs) {
- result.add(new BasicX509Credential(cert));
-
- }
- return result;
-
- } catch (final KeyStoreException e) {
- throw new EaafConfigurationException("module.eidasauth.01",
- new Object[] { "Trusted metadata-signing certificates", e.getMessage() }, e);
-
- }
- }
}
diff --git a/connector_lib/pom.xml b/connector_lib/pom.xml
index 52a6c32d..795096f9 100644
--- a/connector_lib/pom.xml
+++ b/connector_lib/pom.xml
@@ -23,6 +23,10 @@
<groupId>at.gv.egiz.eaaf</groupId>
<artifactId>eaaf-core</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-webmvc</artifactId>
+ </dependency>
<dependency>
<groupId>javax.servlet</groupId>
diff --git a/connector_lib/src/main/java/at/asitplus/eidas/specific/connector/gui/GuiBuilderConfigurationFactory.java b/connector_lib/src/main/java/at/asitplus/eidas/specific/connector/gui/GuiBuilderConfigurationFactory.java
index 9cef3db3..91713cd4 100644
--- a/connector_lib/src/main/java/at/asitplus/eidas/specific/connector/gui/GuiBuilderConfigurationFactory.java
+++ b/connector_lib/src/main/java/at/asitplus/eidas/specific/connector/gui/GuiBuilderConfigurationFactory.java
@@ -26,6 +26,8 @@ package at.asitplus.eidas.specific.connector.gui;
import java.net.MalformedURLException;
import java.net.URI;
+import javax.annotation.Nonnull;
+
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.io.ResourceLoader;
import org.springframework.stereotype.Service;
@@ -56,4 +58,12 @@ public class GuiBuilderConfigurationFactory implements IGuiBuilderConfigurationF
MsEidasNodeConstants.TEMPLATE_HTML_PVP_POSTBINDING, null, resourceLoader);
}
+ @Override
+ public IGuiBuilderConfiguration getDefaultIFrameParentHopGui(IRequest pendingReq,
+ @Nonnull String endpoint, @Nonnull String errorId) {
+ //TODO: implement if iFrame to parent hop is needed
+ throw new RuntimeException("Operation not supported yet.");
+
+ }
+
}
diff --git a/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java b/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java
index 0c080b32..2f6a989e 100644
--- a/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java
+++ b/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java
@@ -58,7 +58,7 @@ import szrservices.PersonInfoType;
import szrservices.SZRException_Exception;
import szrservices.TravelDocumentType;
-@Ignore
+//@Ignore
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration("/SpringTest-context_basic_test.xml")
public class SzrClientTestProduction {
@@ -73,7 +73,7 @@ public class SzrClientTestProduction {
private static final String familyName = "Mustermann";
// private static final String dateOfBirth = "1989-05-05";
private static final String dateOfBirth = "1989-05-04";
- private static final String eIDASeID = "IS/AT/1234sdgsdfg56789ABCDEF";
+ private static final String eIDASeID = "IS/AT/1234ffgsdfg56789ABCDEF";
private static final String DUMMY_TARGET = EaafConstants.URN_PREFIX_CDID + "ZP";
diff --git a/eidas_modules/authmodule-eIDAS-v2/src/test/resources/SpringTest-context_basic_test.xml b/eidas_modules/authmodule-eIDAS-v2/src/test/resources/SpringTest-context_basic_test.xml
index f1f13391..0bb5d419 100644
--- a/eidas_modules/authmodule-eIDAS-v2/src/test/resources/SpringTest-context_basic_test.xml
+++ b/eidas_modules/authmodule-eIDAS-v2/src/test/resources/SpringTest-context_basic_test.xml
@@ -17,6 +17,29 @@
<!-- <bean id="eIDASDataStore" class="at.asitplus.eidas.specific.modules.auth.eidas.v2.service.eIDASDataStore"
/> -->
+ <bean id="springManagedSpecificConnectorCommunicationService"
+ class="at.asitplus.eidas.specific.modules.auth.eidas.v2.test.dummy.DummySpecificCommunicationService" />
+
+ <bean id="specificConnectorAttributesFileWithPath"
+ class="java.lang.String">
+ <constructor-arg
+ value="src/test/resources/config/eidas-attributes.xml" />
+ </bean>
+
+ <bean id="specificConnectorAdditionalAttributesFileWithPath"
+ class="java.lang.String">
+ <constructor-arg
+ value="src/test/resources/config/additional-attributes.xml" />
+ </bean>
+
+ <bean id="attributeRegistry"
+ class="at.asitplus.eidas.specific.modules.auth.eidas.v2.service.EidasAttributeRegistry">
+ <property name="eidasAttributesFile"
+ ref="specificConnectorAttributesFileWithPath" />
+ <property name="additionalAttributesFile"
+ ref="specificConnectorAdditionalAttributesFileWithPath" />
+ </bean>
+
<bean id="EIDPostProcessingService"
class="at.asitplus.eidas.specific.modules.auth.eidas.v2.service.CcSpecificEidProcessingService" />
diff --git a/pom.xml b/pom.xml
index 50bdfaf4..8e0019d4 100644
--- a/pom.xml
+++ b/pom.xml
@@ -19,35 +19,38 @@
<!-- ===================================================================== -->
<egiz-spring-api>0.3</egiz-spring-api>
<egiz-eventlog-slf4jBackend>0.4</egiz-eventlog-slf4jBackend>
- <eaaf-core.version>1.1.0-SNAPSHOT</eaaf-core.version>
-
- <org.springframework.version>5.2.2.RELEASE</org.springframework.version>
+ <eaaf-core.version>1.1.8</eaaf-core.version>
+ <org.springframework.version>5.2.9.RELEASE</org.springframework.version>
<org.thymeleaf-spring5.version>3.0.11.RELEASE</org.thymeleaf-spring5.version>
- <cxf.version>3.3.4</cxf.version>
+ <cxf.version>3.4.0</cxf.version>
- <org.apache.commons-lang3.version>3.9</org.apache.commons-lang3.version>
- <org.apache.commons-text.version>1.8</org.apache.commons-text.version>
+ <org.apache.commons-lang3.version>3.11</org.apache.commons-lang3.version>
+ <org.apache.commons-text.version>1.9</org.apache.commons-text.version>
<commons-collections4.version>4.4</commons-collections4.version>
- <com.google.guava.version>28.1-jre</com.google.guava.version>
- <joda-time.version>2.10.5</joda-time.version>
+ <com.google.guava.version>29.0-jre</com.google.guava.version>
+ <joda-time.version>2.10.6</joda-time.version>
+ <org.slf4j.version>1.7.30</org.slf4j.version>
+
+ <!-- testing -->
+ <junit.version>4.13</junit.version>
<surefire.version>2.22.2</surefire.version>
- <org.slf4j.version>1.7.29</org.slf4j.version>
<mockito-soap-cxf.version>1.0.5</mockito-soap-cxf.version>
-
<!-- Code quality checks -->
- <jacoco-maven-plugin.version>0.8.5</jacoco-maven-plugin.version>
- <maven-checkstyle-plugin.version>3.1.0</maven-checkstyle-plugin.version>
- <maven-pmd-plugin.version>3.12.0</maven-pmd-plugin.version>
- <spotbugs-maven-plugin.version>3.1.12.2</spotbugs-maven-plugin.version>
+ <jacoco-maven-plugin.version>0.8.6</jacoco-maven-plugin.version>
+ <maven-checkstyle-plugin.version>3.1.1</maven-checkstyle-plugin.version>
+ <maven-pmd-plugin.version>3.13.0</maven-pmd-plugin.version>
+ <spotbugs-maven-plugin.version>4.0.4</spotbugs-maven-plugin.version>
<license.outputDirectory>${project.build.directory}/thirdparty_licenses</license.outputDirectory>
<pmw_rules_location>https://apps.egiz.gv.at/checkstyle/egiz_pmd_checks.xml</pmw_rules_location>
<!-- Build and assembly -->
+ <maven-compiler-plugin.version>3.8.1</maven-compiler-plugin.version>
+ <versions-maven-plugin.version>2.8.1</versions-maven-plugin.version>
<license-maven-plugin>1.20</license-maven-plugin>
- <maven-assembly-plugin.version>3.2.0</maven-assembly-plugin.version>
+ <maven-assembly-plugin.version>3.3.0</maven-assembly-plugin.version>
</properties>
@@ -204,7 +207,7 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
- <version>4.12</version>
+ <version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
@@ -243,7 +246,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
- <version>3.7.0</version>
+ <version>${maven-compiler-plugin.version}</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
@@ -275,7 +278,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
- <version>2.7</version>
+ <version>${versions-maven-plugin.version}</version>
</plugin>
<plugin>