aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateIdentityLinkTask.java18
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/GenerateAuthnRequestTask.java6
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAuthnResponseTask.java10
-rw-r--r--modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEventCodes.java (renamed from modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsConnectorEventCodes.java)10
-rw-r--r--ms_specific_connector/src/main/java/at/asitplus/eidas/specific/connector/processes/tasks/GenerateCountrySelectionFrameTask.java4
5 files changed, 26 insertions, 22 deletions
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateIdentityLinkTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateIdentityLinkTask.java
index 2379f39e..f98c6fe5 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateIdentityLinkTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateIdentityLinkTask.java
@@ -36,7 +36,7 @@ import org.w3c.dom.Element;
import com.fasterxml.jackson.core.JsonProcessingException;
-import at.asitplus.eidas.specific.core.MsConnectorEventCodes;
+import at.asitplus.eidas.specific.core.MsEventCodes;
import at.asitplus.eidas.specific.core.MsEidasNodeConstants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.clients.szr.SzrClient;
@@ -183,19 +183,19 @@ public class CreateIdentityLinkTask extends AbstractAuthServletTask {
String vsz = szrClient.getEncryptedStammzahl(matchedPersonData);
//write revision-Log entry and extended infos personal-identifier mapping
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.SZR_VSZ_RECEIVED);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.SZR_VSZ_RECEIVED);
writeExtendedRevisionLogEntry(eidData, eidData.getPersonalIdentifier());
// get eIDAS bind
String signedEidasBind = szrClient
.getEidasBind(vsz, authBlockSigner.getBase64EncodedPublicKey(), EID_STATUS, matchedPersonData);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.SZR_EIDASBIND_RECEIVED);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.SZR_EIDASBIND_RECEIVED);
AuthProcessDataWrapper authProcessDataWrapper = MatchingTaskUtils.getAuthProcessDataWrapper(pendingReq);
authProcessDataWrapper.setGenericDataToSession(MsEidasNodeConstants.AUTH_DATA_EIDAS_BIND, signedEidasBind);
//get signed AuthBlock
String jwsSignature = authBlockSigner.buildSignedAuthBlock(pendingReq);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.TECH_AUCHBLOCK_CREATED);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.TECH_AUCHBLOCK_CREATED);
authProcessDataWrapper.setGenericDataToSession(MsEidasNodeConstants.AUTH_DATA_SZR_AUTHBLOCK, jwsSignature);
//inject personal-data into session
@@ -207,8 +207,8 @@ public class CreateIdentityLinkTask extends AbstractAuthServletTask {
// write ERnP input-data into revision-log
if (basicConfig.getBasicConfigurationBoolean(
Constants.CONIG_PROPS_EIDAS_SZRCLIENT_WORKAROUND_REVISIONLOGDATASTORE_ACTIVE, false)) {
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.SZR_ERNB_EIDAS_RAW_ID, personalIdentifier);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.SZR_ERNB_EIDAS_ERNB_ID, eidData.getPseudonym());
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.SZR_ERNB_EIDAS_RAW_ID, personalIdentifier);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.SZR_ERNB_EIDAS_ERNB_ID, eidData.getPseudonym());
}
}
@@ -254,7 +254,7 @@ public class CreateIdentityLinkTask extends AbstractAuthServletTask {
String assertionId = idlResult.getIdentityLink().getSamlAssertion()
.getAttribute(SimpleIdentityLinkAssertionParser.ASSERTIONID);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.SZR_IDL_RECEIVED, assertionId);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.SZR_IDL_RECEIVED, assertionId);
if (idlResult.getBpK() == null) {
log.error("ERnB did not return a bPK for target: " + pendingReq.getServiceProviderConfiguration()
@@ -262,7 +262,7 @@ public class CreateIdentityLinkTask extends AbstractAuthServletTask {
throw new SzrCommunicationException("ernb.01", null);
}
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.SZR_BPK_RECEIVED);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.SZR_BPK_RECEIVED);
log.debug("ERnB communication was successfull");
}
@@ -306,7 +306,7 @@ public class CreateIdentityLinkTask extends AbstractAuthServletTask {
.getBasicConfigurationBoolean(MsEidasNodeConstants.PROP_CONFIG_REVISIONLOG_WRITE_MDS_INTO_REVISION_LOG,
false);
if (writeMdsInRevLog) {
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.RESPONSE_FROM_EIDAS_MDSDATA,
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.RESPONSE_FROM_EIDAS_MDSDATA,
"{" + eidData.getGivenName() + "," + eidData.getFamilyName() + "," + eidData
.getDateOfBirth() + "," + eidData.getCitizenCountryCode() + "}");
}
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/GenerateAuthnRequestTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/GenerateAuthnRequestTask.java
index f14c8f90..f2318386 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/GenerateAuthnRequestTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/GenerateAuthnRequestTask.java
@@ -37,7 +37,7 @@ import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.Component;
import org.springframework.web.util.UriComponentsBuilder;
-import at.asitplus.eidas.specific.core.MsConnectorEventCodes;
+import at.asitplus.eidas.specific.core.MsEventCodes;
import at.asitplus.eidas.specific.core.MsEidasNodeConstants;
import at.asitplus.eidas.specific.core.gui.StaticGuiBuilderConfiguration;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
@@ -137,7 +137,7 @@ public class GenerateAuthnRequestTask extends AbstractAuthServletTask {
}
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.EIDAS_NODE_CONNECTED, lightAuthnReq.getId());
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.EIDAS_NODE_CONNECTED, lightAuthnReq.getId());
log.info("Allowed LoA: {}",
StringUtils.join(pendingReq.getServiceProviderConfiguration().getRequiredLoA(),", "));
@@ -159,7 +159,7 @@ public class GenerateAuthnRequestTask extends AbstractAuthServletTask {
}
// TODO: maybe add countryCode validation before request ref. impl. eIDAS node
log.info("Request eIDAS auth. for citizen of country: {}", result);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.COUNTRY_SELECTED, result);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.COUNTRY_SELECTED, result);
return result;
}
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAuthnResponseTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAuthnResponseTask.java
index 15d2616c..a736ae08 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAuthnResponseTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAuthnResponseTask.java
@@ -35,7 +35,7 @@ import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.Component;
import org.springframework.web.util.UriComponentsBuilder;
-import at.asitplus.eidas.specific.core.MsConnectorEventCodes;
+import at.asitplus.eidas.specific.core.MsEventCodes;
import at.asitplus.eidas.specific.core.MsEidasNodeConstants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.exception.EidasSAuthenticationException;
@@ -114,13 +114,13 @@ public class ReceiveAuthnResponseTask extends AbstractAuthServletTask {
StringUtils.join(pendingReq.getServiceProviderConfiguration().getRequiredLoA(),", "));
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.RESPONSE_FROM_EIDAS_NODE_VALID);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.RESPONSE_FROM_EIDAS_NODE_VALID);
} catch (final EaafException e) {
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.RESPONSE_FROM_EIDAS_NODE_NOT_VALID);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.RESPONSE_FROM_EIDAS_NODE_NOT_VALID);
throw new TaskExecutionException(pendingReq, "eIDAS Response processing FAILED.", e);
} catch (final Exception e) {
log.warn("eIDAS Response processing FAILED.", e);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.RESPONSE_FROM_EIDAS_NODE_NOT_VALID);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.RESPONSE_FROM_EIDAS_NODE_NOT_VALID);
throw new TaskExecutionException(pendingReq, e.getMessage(),
new EidasSAuthenticationException("eidas.05", new Object[]{e.getMessage()}, e));
}
@@ -162,7 +162,7 @@ public class ReceiveAuthnResponseTask extends AbstractAuthServletTask {
log.debug("Receive eIDAS response with RespId: {} for ReqId: {}",
eidasResponse.getId(), eidasResponse.getInResponseToId());
log.trace("Full eIDAS-Resp: {}", eidasResponse);
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.RESPONSE_FROM_EIDAS_NODE, eidasResponse.getId());
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.RESPONSE_FROM_EIDAS_NODE, eidasResponse.getId());
return eidasResponse;
}
diff --git a/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsConnectorEventCodes.java b/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEventCodes.java
index d15cf77c..b3c36c75 100644
--- a/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsConnectorEventCodes.java
+++ b/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEventCodes.java
@@ -23,7 +23,7 @@
package at.asitplus.eidas.specific.core;
-public class MsConnectorEventCodes {
+public class MsEventCodes {
public static final int STARTING_COUNTRY_SELECTION = 4100;
public static final int COUNTRY_SELECTED = 4101;
@@ -44,9 +44,13 @@ public class MsConnectorEventCodes {
public static final int SZR_ERNB_EIDAS_RAW_ID = 6210;
public static final int SZR_ERNB_EIDAS_ERNB_ID = 6211;
-
- private MsConnectorEventCodes() {
+ public static final int EIDAS_OUTGOING_RECEIVED = 6500;
+ public static final int EIDAS_OUTGOING_RESPOND = 6501;
+
+
+
+ private MsEventCodes() {
// hidden constructor for class with static values only.
}
}
diff --git a/ms_specific_connector/src/main/java/at/asitplus/eidas/specific/connector/processes/tasks/GenerateCountrySelectionFrameTask.java b/ms_specific_connector/src/main/java/at/asitplus/eidas/specific/connector/processes/tasks/GenerateCountrySelectionFrameTask.java
index 57a4c19a..70639f58 100644
--- a/ms_specific_connector/src/main/java/at/asitplus/eidas/specific/connector/processes/tasks/GenerateCountrySelectionFrameTask.java
+++ b/ms_specific_connector/src/main/java/at/asitplus/eidas/specific/connector/processes/tasks/GenerateCountrySelectionFrameTask.java
@@ -29,7 +29,7 @@ import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
-import at.asitplus.eidas.specific.core.MsConnectorEventCodes;
+import at.asitplus.eidas.specific.core.MsEventCodes;
import at.asitplus.eidas.specific.core.MsEidasNodeConstants;
import at.asitplus.eidas.specific.core.gui.StaticGuiBuilderConfiguration;
import at.gv.egiz.eaaf.core.api.gui.IGuiBuilderConfiguration;
@@ -59,7 +59,7 @@ public class GenerateCountrySelectionFrameTask extends AbstractLocaleAuthServlet
public void executeWithLocale(ExecutionContext executionContext, HttpServletRequest request,
HttpServletResponse response) throws TaskExecutionException {
try {
- revisionsLogger.logEvent(pendingReq, MsConnectorEventCodes.STARTING_COUNTRY_SELECTION);
+ revisionsLogger.logEvent(pendingReq, MsEventCodes.STARTING_COUNTRY_SELECTION);
final IGuiBuilderConfiguration config = new StaticGuiBuilderConfiguration(
basicConfig,