| commit | 8a279d7de4cf94c99f655f6edd0da0c24ab4003c | [log] |
|---|---|---|
| author | Miklos Vajna <vmiklos@collabora.co.uk> | Thu Nov 24 12:23:30 2016 +0100 |
| committer | Miklos Vajna <vmiklos@collabora.co.uk> | Thu Nov 24 16:08:04 2016 +0000 |
| tree | b7ea8a600a440a41e3e6acbf68ecd9c658cd01df | |
| parent | d04a05a7d4692dcb3083d1089a3f4e78fb07bcbf [diff] |
xmlsecurity mscrypto PDF sign: conditionally add back CAdES SubFilter We can now write that on Windows as well when requested, after the signing-certificate attribute is implemented using mscrypto. With this, the PAdES validator at <http://signatures-conformance-checker.etsi.org/protected/upload.php?sigtype=padesconf> finds our Windows signature valid. Change-Id: Iaeb4c36a1eac14e3d3c3c12d9cfd9529e7663f77 Reviewed-on: https://gerrit.libreoffice.org/31162 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
diff --git a/xmlsecurity/source/pdfio/pdfdocument.cxx b/xmlsecurity/source/pdfio/pdfdocument.cxx index 648cc4b..1537500 100644 --- a/xmlsecurity/source/pdfio/pdfdocument.cxx +++ b/xmlsecurity/source/pdfio/pdfdocument.cxx
@@ -375,13 +375,9 @@ sal_Int32 PDFDocument::WriteSignatureObject(const OUString& rDescription, bool b comphelper::string::padToLength(aContentFiller, MAX_SIGNATURE_CONTENT_LENGTH, '0'); aSigBuffer.append(aContentFiller.makeStringAndClear()); aSigBuffer.append(">\n/Type/Sig/SubFilter"); #ifdef XMLSEC_CRYPTO_NSS if (bAdES) aSigBuffer.append("/ETSI.CAdES.detached"); else #else (void)bAdES; #endif aSigBuffer.append("/adbe.pkcs7.detached"); // Time of signing.