aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas <>2022-07-01 17:11:54 +0200
committerThomas <>2022-07-01 17:11:54 +0200
commite25d3559d2747b60c19dab90a0b6524e7e7eed3a (patch)
tree4c683b3bbbf6a8d25423cf5a94e7b31d37f30ef1
parent99351e33f4e3e47bb2496c9c656d671079876742 (diff)
downloadNational_eIDAS_Gateway-e25d3559d2747b60c19dab90a0b6524e7e7eed3a.tar.gz
National_eIDAS_Gateway-e25d3559d2747b60c19dab90a0b6524e7e7eed3a.tar.bz2
National_eIDAS_Gateway-e25d3559d2747b60c19dab90a0b6524e7e7eed3a.zip
style(matching): fix code-style issue
-rw-r--r--basicConfig/templates/other_login_method.html2
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/AlternativeSearchTask.java4
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateNewErnpEntryTask.java4
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/InitialSearchTask.java6
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAustrianResidenceGuiResponseTask.java6
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveMobilePhoneSignatureResponseTask.java4
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveOtherLoginMethodGuiResponseTask.java4
-rw-r--r--modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/utils/MatchingTaskUtils.java4
-rw-r--r--modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEidasNodeConstants.java5
-rw-r--r--modules/core_common_webapp/src/main/java/at/asitplus/eidas/specific/core/logger/StatisticLogger.java2
10 files changed, 20 insertions, 21 deletions
diff --git a/basicConfig/templates/other_login_method.html b/basicConfig/templates/other_login_method.html
index 31ff74a6..d392a553 100644
--- a/basicConfig/templates/other_login_method.html
+++ b/basicConfig/templates/other_login_method.html
@@ -150,7 +150,7 @@
<!-- Abbrechen Button -->
<form class="block,singleButton" method="post" action="$contextPath$submitEndpoint" th:attr="action=@{${submitEndpoint}}">
<button type="submit" value="Abbrechen/Cancel" th:text="#{gui.otherlogin.cancel}"></button>
- <input type="hidden" name="STOP_MATCHING_PROCESS" value="true">
+ <input type="hidden" name="loginSelection" value="STOP_MATCHING_PROCESS">
<input type="hidden" name="pendingid" value="$pendingid" th:attr="value=${pendingid}">
</form>
</div>
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/AlternativeSearchTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/AlternativeSearchTask.java
index ccc84f46..dd46bfea 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/AlternativeSearchTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/AlternativeSearchTask.java
@@ -36,7 +36,7 @@ import javax.servlet.http.HttpServletResponse;
import org.jetbrains.annotations.NotNull;
import org.springframework.stereotype.Component;
-import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.MatchedPersonResult;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.SimpleEidasData;
@@ -244,7 +244,7 @@ public class AlternativeSearchTask extends AbstractAuthServletTask {
throws WorkflowException, EaafStorageException {
MatchedPersonResult result = MatchedPersonResult.generateFormMatchingResult(
searchResult.getResult(), eidasData.getCitizenCountryCode());
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_EIDAS);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_EIDAS);
MatchingTaskUtils.storeFinalMatchingResult(pendingReq, result);
//remove intermediate matching-state
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateNewErnpEntryTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateNewErnpEntryTask.java
index 6680650e..563a66ba 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateNewErnpEntryTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/CreateNewErnpEntryTask.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.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.clients.ernp.ErnpRestClient;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.clients.ernp.ErnpRestClient.ErnpRegisterResult;
@@ -93,7 +93,7 @@ public class CreateNewErnpEntryTask extends AbstractAuthServletTask {
// finish matching process, because new user-entry uniquly matches
log.info("User successfully registerred into ERnP and matching tasks are finished ");
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_NEW_ERNP_ENTRY);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_NEW_ERNP_ENTRY);
MatchingTaskUtils.storeFinalMatchingResult(pendingReq,
MatchedPersonResult.generateFormMatchingResult(
resp.getPersonResult().get(0), simpleEidasData.getCitizenCountryCode()));
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/InitialSearchTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/InitialSearchTask.java
index 86d279c6..8e6c7790 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/InitialSearchTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/InitialSearchTask.java
@@ -34,7 +34,7 @@ import javax.servlet.http.HttpServletResponse;
import org.jetbrains.annotations.NotNull;
import org.springframework.stereotype.Component;
-import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.MatchedPersonResult;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.RegisterResult;
@@ -125,7 +125,7 @@ public class InitialSearchTask extends AbstractAuthServletTask {
} else if (resultCount == 1) {
RegisterResult updatedResult = step3CheckRegisterUpdateNecessary(searchResult, eidasData);
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_PERSONALID);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_PERSONALID);
foundMatchFinalizeTask(updatedResult, eidasData);
} else {
@@ -153,7 +153,7 @@ public class InitialSearchTask extends AbstractAuthServletTask {
} else if (searchResult.getResultCount() == 1) {
log.trace("'step6CountrySpecificSearch' finds a person. Forward to 'step7aKittProcess' step ... ");
RegisterStatusResults updatedResult = registerSearchService.step7aKittProcess(searchResult, eidasData);
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_COUNTRY_SPECIFIC);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_COUNTRY_SPECIFIC);
foundMatchFinalizeTask(updatedResult.getResult(), eidasData);
} else {
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAustrianResidenceGuiResponseTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAustrianResidenceGuiResponseTask.java
index 00a7e28d..09ef0129 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAustrianResidenceGuiResponseTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveAustrianResidenceGuiResponseTask.java
@@ -41,7 +41,7 @@ import org.springframework.stereotype.Component;
import com.google.common.collect.Sets;
-import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.controller.AdresssucheController;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.controller.AdresssucheController.AdresssucheOutput;
@@ -187,7 +187,7 @@ public class ReceiveAustrianResidenceGuiResponseTask extends AbstractLocaleAuthS
RegisterStatusResults updateResult = registerSearchService.step7aKittProcess(residencyResult, eidasData);
// store updated result to re-used in CreateIdentityLink step, because there we need bPK and MDS
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_ADDRESS);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_ADDRESS);
MatchingTaskUtils.storeFinalMatchingResult(pendingReq,
MatchedPersonResult.generateFormMatchingResult(
updateResult.getResult(), eidasData.getCitizenCountryCode()));
@@ -195,7 +195,7 @@ public class ReceiveAustrianResidenceGuiResponseTask extends AbstractLocaleAuthS
} else {
log.warn("Suspect state FOUND. Matching by residence was neccessary but NO register-update are required!");
// no update required. Data can be used as it is.
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_ADDRESS);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_ADDRESS);
MatchingTaskUtils.storeFinalMatchingResult(pendingReq,
MatchedPersonResult.generateFormMatchingResult(
residencyResult.getResult(), eidasData.getCitizenCountryCode()));
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveMobilePhoneSignatureResponseTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveMobilePhoneSignatureResponseTask.java
index 11ac9549..57790b01 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveMobilePhoneSignatureResponseTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveMobilePhoneSignatureResponseTask.java
@@ -47,7 +47,7 @@ import org.opensaml.saml.saml2.core.StatusCode;
import org.opensaml.saml.saml2.metadata.IDPSSODescriptor;
import org.springframework.stereotype.Component;
-import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.MatchedPersonResult;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.RegisterResult;
@@ -205,7 +205,7 @@ public class ReceiveMobilePhoneSignatureResponseTask extends AbstractAuthServlet
registerSearchService.step7aKittProcess(registerResult, eidasData);
// store search result to re-used in CreateIdentityLink step, because there we need bPK and MDS
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.BY_ID_AUSTRIA);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.BY_ID_AUSTRIA);
MatchingTaskUtils.storeFinalMatchingResult(pendingReq,
MatchedPersonResult.generateFormMatchingResult(registerResult.getResult(),
eidasData.getCitizenCountryCode()));
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveOtherLoginMethodGuiResponseTask.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveOtherLoginMethodGuiResponseTask.java
index 159b5b51..03414f9e 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveOtherLoginMethodGuiResponseTask.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/tasks/ReceiveOtherLoginMethodGuiResponseTask.java
@@ -34,7 +34,7 @@ import org.springframework.stereotype.Component;
import com.google.common.collect.Sets;
-import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.SelectedLoginMethod;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.utils.MatchingTaskUtils;
@@ -112,7 +112,7 @@ public class ReceiveOtherLoginMethodGuiResponseTask extends AbstractLocaleAuthSe
switch (selection) {
case STOP_MATCHING_PROCESS:
log.info("Matching process WAS stopped by entity. Stopping auth. process ... ");
- MatchingTaskUtils.setMatchingState(pendingReq, MATCHING_STATES.CANCELED_BY_USER);
+ MatchingTaskUtils.setMatchingState(pendingReq, MatchingStates.CANCELED_BY_USER);
stopProcessFromUserDecision(executionContext, request, response);
return;
diff --git a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/utils/MatchingTaskUtils.java b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/utils/MatchingTaskUtils.java
index 8ecefe49..c350cb05 100644
--- a/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/utils/MatchingTaskUtils.java
+++ b/modules/authmodule-eIDAS-v2/src/main/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/utils/MatchingTaskUtils.java
@@ -16,7 +16,7 @@ import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
import at.asitplus.eidas.specific.core.MsEidasNodeConstants;
-import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MATCHING_STATES;
+import at.asitplus.eidas.specific.core.MsEidasNodeConstants.MatchingStates;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.MatchedPersonResult;
import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.SimpleEidasData;
@@ -122,7 +122,7 @@ public class MatchingTaskUtils {
* @param pendingReq Current pendingRequest
* @param state Operation that results into a person match
*/
- public static void setMatchingState(IRequest pendingReq, MATCHING_STATES state) {
+ public static void setMatchingState(IRequest pendingReq, MatchingStates state) {
try {
pendingReq.setRawDataToTransaction(MsEidasNodeConstants.DATA_MATCHING_STATE, state);
diff --git a/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEidasNodeConstants.java b/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEidasNodeConstants.java
index eb7c90f2..835070b1 100644
--- a/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEidasNodeConstants.java
+++ b/modules/core_common_lib/src/main/java/at/asitplus/eidas/specific/core/MsEidasNodeConstants.java
@@ -238,7 +238,7 @@ public class MsEidasNodeConstants {
});
- public enum MATCHING_STATES {
+ public enum MatchingStates {
NO_REQUIRED,
CANCELED_BY_USER,
BY_PERSONALID,
@@ -246,8 +246,7 @@ public class MsEidasNodeConstants {
BY_ID_AUSTRIA,
BY_EIDAS,
BY_ADDRESS,
- BY_NEW_ERNP_ENTRY
- };
+ BY_NEW_ERNP_ENTRY }
private MsEidasNodeConstants() {
//hidden Constructor for class with static values only.
diff --git a/modules/core_common_webapp/src/main/java/at/asitplus/eidas/specific/core/logger/StatisticLogger.java b/modules/core_common_webapp/src/main/java/at/asitplus/eidas/specific/core/logger/StatisticLogger.java
index c2c8d368..22cace10 100644
--- a/modules/core_common_webapp/src/main/java/at/asitplus/eidas/specific/core/logger/StatisticLogger.java
+++ b/modules/core_common_webapp/src/main/java/at/asitplus/eidas/specific/core/logger/StatisticLogger.java
@@ -118,7 +118,7 @@ public class StatisticLogger implements IStatisticLogger {
}
private String extractMatchingState(Object state) {
- return state != null ? state.toString() : MsEidasNodeConstants.MATCHING_STATES.NO_REQUIRED.toString();
+ return state != null ? state.toString() : MsEidasNodeConstants.MatchingStates.NO_REQUIRED.toString();
}