aboutsummaryrefslogtreecommitdiff
path: root/id/server/idserverlib/src/main/java/at/gv
diff options
context:
space:
mode:
Diffstat (limited to 'id/server/idserverlib/src/main/java/at/gv')
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java36
1 files changed, 24 insertions, 12 deletions
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java
index 085874e77..6a01bd1fb 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java
@@ -912,18 +912,30 @@ public class AuthenticationDataBuilder extends AbstractAuthenticationDataBuilder
private void generateAdditonalbPK(MOAAuthenticationData authData, List<String> additionalbPKSectorsRequested) throws EAAFBuilderException {
if (additionalbPKSectorsRequested != null && !additionalbPKSectorsRequested.isEmpty()) {
- Logger.debug("Sectors for foreign bPKs are configurated. Starting foreign bPK generation ... ");
- for (String sector : additionalbPKSectorsRequested) {
- Logger.trace("Process sector: " + sector + " ... ");
- Pair<String, String> bpk = new BPKBuilder().generateAreaSpecificPersonIdentifier(
- authData.getIdentificationValue(),
- authData.getIdentificationType(),
- sector);
-
- Logger.trace("Calculate additional bPK for sector: " + bpk.getSecond() + " with value: " + bpk.getFirst() );
- authData.addAdditionalbPKPair(bpk);
-
- }
+ Logger.debug("Sectors for foreign bPKs are configurated. Starting foreign bPK generation ... ");
+
+ try {
+ for (String sector : additionalbPKSectorsRequested) {
+ Logger.trace("Process sector: " + sector + " ... ");
+ Pair<String, String> bpk = new BPKBuilder().generateAreaSpecificPersonIdentifier(
+ authData.getIdentificationValue(),
+ authData.getIdentificationType(),
+ sector);
+
+ Logger.trace("Calculate additional bPK for sector: " + bpk.getSecond() + " with value: " + bpk.getFirst() );
+ authData.addAdditionalbPKPair(bpk);
+
+ }
+
+ } catch (Exception e) {
+ Logger.warn("Can NOT generate additional bPKs. Reason: " + e.getMessage());
+
+ if (Logger.isDebugEnabled()) {
+ Logger.warn("StackTrace: ", e);
+
+ }
+
+ }
}
}
@Override