diff options
author | Tor Lillqvist <tml@collabora.com> | 2015-02-19 11:34:52 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2015-03-05 15:20:42 +0100 |
commit | bed9f10da45c94feda7201acc91a553b4ab08cc6 (patch) | |
tree | b1177b07c0bcc8ae46f54050d4e18c2af94e273f /vcl | |
parent | ce7e307c80fd18b70a0c7bd348e0f9697056980b (diff) |
tdf#84881: reqPolicy and certReq are optional
Change-Id: Ia5687bf2d68eef06aeb618d5387c663807d24560
(cherry picked from commit 2ddfaa6d323b5db2f59f06f7708c5209549abeee)
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/gdi/pdfwriter_impl.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx index cd066dd358de..a846658cb152 100644 --- a/vcl/source/gdi/pdfwriter_impl.cxx +++ b/vcl/source/gdi/pdfwriter_impl.cxx @@ -6118,9 +6118,9 @@ const SEC_ASN1Template TimeStampReq_Template[] = { SEC_ASN1_SEQUENCE, 0, NULL, sizeof(TimeStampReq) }, { SEC_ASN1_INTEGER, offsetof(TimeStampReq, version), 0, 0 }, { SEC_ASN1_INLINE | SEC_ASN1_XTRN, offsetof(TimeStampReq, messageImprint), SEC_ASN1_SUB(MessageImprint_Template), 0 }, - { SEC_ASN1_OBJECT_ID, offsetof(TimeStampReq, reqPolicy), 0, 0 }, + { SEC_ASN1_OBJECT_ID | SEC_ASN1_OPTIONAL, offsetof(TimeStampReq, reqPolicy), 0, 0 }, { SEC_ASN1_INTEGER | SEC_ASN1_OPTIONAL, offsetof(TimeStampReq, nonce), 0, 0 }, - { SEC_ASN1_BOOLEAN, offsetof(TimeStampReq, certReq), 0, 0 }, + { SEC_ASN1_BOOLEAN | SEC_ASN1_OPTIONAL, offsetof(TimeStampReq, certReq), 0, 0 }, { SEC_ASN1_XTRN | SEC_ASN1_OPTIONAL | SEC_ASN1_CONTEXT_SPECIFIC | 0, offsetof(TimeStampReq, extensions), SEC_ASN1_SUB(Extensions_Template), 0 }, { 0, 0, 0, 0 } }; @@ -6302,10 +6302,9 @@ bool PDFWriterImpl::finalizeSignature() src.nonce.data = reinterpret_cast<unsigned char*>(&nNonce); src.nonce.len = sizeof(nNonce); - unsigned char cFalse = false; - src.certReq.type = siUnsignedInteger; - src.certReq.data = &cFalse; - src.certReq.len = sizeof(cFalse); + src.certReq.type = siBuffer; + src.certReq.data = NULL; + src.certReq.len = 0; src.extensions = NULL; |