summaryrefslogtreecommitdiff
path: root/eaaf_modules/eaaf_module_moa-sig/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'eaaf_modules/eaaf_module_moa-sig/src/main')
-rw-r--r--eaaf_modules/eaaf_module_moa-sig/src/main/java/at/gv/egiz/eaaf/modules/sigverify/moasig/impl/data/GenericSignatureVerificationResponse.java22
1 files changed, 20 insertions, 2 deletions
diff --git a/eaaf_modules/eaaf_module_moa-sig/src/main/java/at/gv/egiz/eaaf/modules/sigverify/moasig/impl/data/GenericSignatureVerificationResponse.java b/eaaf_modules/eaaf_module_moa-sig/src/main/java/at/gv/egiz/eaaf/modules/sigverify/moasig/impl/data/GenericSignatureVerificationResponse.java
index 28501c54..6006b731 100644
--- a/eaaf_modules/eaaf_module_moa-sig/src/main/java/at/gv/egiz/eaaf/modules/sigverify/moasig/impl/data/GenericSignatureVerificationResponse.java
+++ b/eaaf_modules/eaaf_module_moa-sig/src/main/java/at/gv/egiz/eaaf/modules/sigverify/moasig/impl/data/GenericSignatureVerificationResponse.java
@@ -3,6 +3,7 @@ package at.gv.egiz.eaaf.modules.sigverify.moasig.impl.data;
import java.io.Serializable;
import java.security.cert.CertificateException;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.Date;
import java.util.List;
@@ -54,7 +55,7 @@ public class GenericSignatureVerificationResponse
private ExtendedCertificateValidation extendedCertificateValidation;
- private List<ExtendedResult> formValidationResults = new ArrayList<>();
+ private List<ExtendedResult> formValidationResults = null;
@Override
public Date getSigningDateTime() {
@@ -105,6 +106,17 @@ public class GenericSignatureVerificationResponse
}
+ @Override
+ public List<ExtendedResult> getFormValidationResults() {
+ if (formValidationResults == null) {
+ return Collections.emptyList();
+
+ } else {
+ return formValidationResults;
+
+ }
+ }
+
/**
* Set signature creation timestramp.
*
@@ -161,7 +173,13 @@ public class GenericSignatureVerificationResponse
if (formCheckResult != null) {
for (Object elObj : formCheckResult) {
if (elObj instanceof AdESFormResults) {
- AdESFormResults el = (AdESFormResults)elObj;
+ AdESFormResults el = (AdESFormResults)elObj;
+
+ if (formValidationResults == null) {
+ formValidationResults = new ArrayList<>();
+
+ }
+
formValidationResults.add(ExtendedResult.builder()
.code(el.getCode())
.info(el.getName())