[Libreoffice-commits] core.git: xmlsecurity/source
Miklos Vajna
vmiklos at collabora.co.uk
Wed Jul 11 07:12:39 UTC 2018
xmlsecurity/source/component/documentdigitalsignatures.cxx | 4 +---
xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx | 8 ++++++++
2 files changed, 9 insertions(+), 3 deletions(-)
New commits:
commit a9c0289886ee5519d4a718d8e3145d66b187faac
Author: Miklos Vajna <vmiklos at collabora.co.uk>
Date: Tue Jul 10 21:56:59 2018 +0200
xmlsecurity UI: restore lost AdES default for PDF signing
Regression from 13596e704e4b48e8b0892867b3f3fc351a2729f9 (Don't pass ODF
version, just retrieve it directly, 2018-05-17).
Change-Id: Ia031e597c610000db2820920c3dc1b58430dcc12
Reviewed-on: https://gerrit.libreoffice.org/57246
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
diff --git a/xmlsecurity/source/component/documentdigitalsignatures.cxx b/xmlsecurity/source/component/documentdigitalsignatures.cxx
index 2fb87800a6e9..4ac2711bbbc4 100644
--- a/xmlsecurity/source/component/documentdigitalsignatures.cxx
+++ b/xmlsecurity/source/component/documentdigitalsignatures.cxx
@@ -383,9 +383,7 @@ bool DocumentDigitalSignatures::ImplViewSignatures(
SAL_WARN_IF( !bInit, "xmlsecurity.comp", "Error initializing security context!" );
if ( bInit )
{
- if (rxStorage.is())
- // Something ZIP based: ODF or OOXML.
- aSignaturesDialog->SetStorage( rxStorage );
+ aSignaturesDialog->SetStorage(rxStorage);
aSignaturesDialog->SetSignatureStream( xSignStream );
if ( aSignaturesDialog->Execute() )
diff --git a/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx b/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
index 841cb6f6339c..f2bc615ef402 100644
--- a/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
+++ b/xmlsecurity/source/dialogs/digitalsignaturesdialog.cxx
@@ -228,6 +228,14 @@ bool DigitalSignaturesDialog::Init()
void DigitalSignaturesDialog::SetStorage( const css::uno::Reference < css::embed::XStorage >& rxStore )
{
+ if (!rxStore.is())
+ {
+ // PDF supports AdES.
+ m_bAdESCompliant = true;
+ m_pAdESCompliantCB->Check(m_bAdESCompliant);
+ return;
+ }
+
maSignatureManager.mxStore = rxStore;
maSignatureManager.maSignatureHelper.SetStorage( maSignatureManager.mxStore, m_sODFVersion);
More information about the Libreoffice-commits
mailing list