diff options
author | Alexander Marsalek <amarsalek@iaik.tugraz.at> | 2021-04-12 15:58:14 +0200 |
---|---|---|
committer | Alexander Marsalek <amarsalek@iaik.tugraz.at> | 2021-04-12 15:58:14 +0200 |
commit | c0f97e7b1ad5b6256eb935aeab06d159d68d1966 (patch) | |
tree | e014d891f58b87a5ca7dbb5c63e6334d9385c266 /pdf-as-lib/src | |
parent | bc6073700024e4b3c95bcf5bf3e48efb6edd14ab (diff) | |
download | pdf-as-4-c0f97e7b1ad5b6256eb935aeab06d159d68d1966.tar.gz pdf-as-4-c0f97e7b1ad5b6256eb935aeab06d159d68d1966.tar.bz2 pdf-as-4-c0f97e7b1ad5b6256eb935aeab06d159d68d1966.zip |
pdf-as-web signature block parameter handling
Diffstat (limited to 'pdf-as-lib/src')
4 files changed, 12 insertions, 8 deletions
diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/PdfAsImpl.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/PdfAsImpl.java index 55891bb2..b1165f59 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/PdfAsImpl.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/PdfAsImpl.java @@ -148,7 +148,8 @@ public class PdfAsImpl implements PdfAs, IConfigurationConstants, PDFObject pdfObject = signer.buildPDFObject(status); //TODO verify map??? - pdfObject.getStatus().getRequestParameters().putAll(status.getSignParamter().getDynamicSignatureBlockArguments()); + +// pdfObject.getStatus().getRequestParameters().putAll(status.getSignParamter().getDynamicSignatureBlockArguments()); status.setPdfObject(pdfObject); // set Original PDF Document Data diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/CertificateAndRequestParameterResolver.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/CertificateAndRequestParameterResolver.java index 3fe8298b..bd7bb3a8 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/CertificateAndRequestParameterResolver.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/CertificateAndRequestParameterResolver.java @@ -62,7 +62,8 @@ public class CertificateAndRequestParameterResolver implements IResolver { this.ctx = new OgnlContext(null, null, memberAccess); this.ctx = new OgnlContext(null, null, memberAccess); - this.ctx.put(IProfileConstants.DYNAMIC_REQUEST_PARAMETERS, operationStatus.getRequestParameters()); + this.ctx.put(IProfileConstants.DYNAMIC_REQUEST_PARAMETERS, operationStatus.getSignParamter().getDynamicSignatureBlockArguments()); +// this.ctx.put(IProfileConstants.DYNAMIC_REQUEST_PARAMETERS, operationStatus.getRequestParameters()); this.ctx.put("sn", this.certificate.getSerialNumber().toString()); diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/OperationStatus.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/OperationStatus.java index 08dcd249..898b7a00 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/OperationStatus.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/OperationStatus.java @@ -56,7 +56,7 @@ public class OperationStatus implements Serializable { private PDFASBackend backend; private Map<String, String> metaInformations = new HashMap<String, String>(); - private HashMap<String, String> requestParameters = new HashMap<String, String>(); +// private HashMap<String, String> requestParameters = new HashMap<String, String>(); public OperationStatus(ISettings configuration, SignParameter signParameter, PDFASBackend backend) { this.configuration = configuration; @@ -177,7 +177,7 @@ public class OperationStatus implements Serializable { return metaInformations; } - public HashMap<String, String> getRequestParameters() { - return requestParameters; - } +// public HashMap<String, String> getRequestParameters() { +// return requestParameters; +// } } diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/PDFObject.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/PDFObject.java index 6722c69e..0b49aa90 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/PDFObject.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/status/PDFObject.java @@ -25,6 +25,7 @@ package at.gv.egiz.pdfas.lib.impl.status; import java.io.IOException; import java.util.HashMap; +import java.util.Map; import javax.activation.DataSource; @@ -71,7 +72,8 @@ public abstract class PDFObject { public abstract String getPDFVersion(); - public HashMap<String, String> getRequestParameters() { - return status.getRequestParameters(); + public Map<String, String> getRequestParameters() { + return status.getSignParamter().getDynamicSignatureBlockArguments(); +// return status.getRequestParameters();//TODO alex } } |