diff options
author | Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> | 2018-04-20 12:19:12 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-11-08 13:49:09 +0100 |
commit | a797afa58cd441cb7de5e1fe2845c3eff2e9001b (patch) | |
tree | 33292431b72f732558e7bfd0f9792a3878f78049 /include | |
parent | 1ed7d2fef309a8a71b837d355099732c49cde887 (diff) |
Sign Signature Line
This adds a new context menu entry "Sign Signature Line" to signature lines.
You can directly sign the document from there.
Still missing is the updating of the graphic to reflect the valid/invalid
signature state.
Reviewed-on: https://gerrit.libreoffice.org/53778
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
(cherry picked from commit 86e8cfdd54ac1b9413f0c86cbc23a80162806685)
Conflicts:
cui/source/dialogs/SignSignatureLineDialog.cxx
xmlsecurity/source/component/documentdigitalsignatures.cxx
Change-Id: Ib8bc8c57f9d5370a10e379f86f9e41e57c715e3f
Diffstat (limited to 'include')
-rw-r--r-- | include/sfx2/docfile.hxx | 6 | ||||
-rw-r--r-- | include/sfx2/objsh.hxx | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/include/sfx2/docfile.hxx b/include/sfx2/docfile.hxx index 468e11dd2e7b..57c52b81cb95 100644 --- a/include/sfx2/docfile.hxx +++ b/include/sfx2/docfile.hxx @@ -35,6 +35,7 @@ #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/ucb/XContent.hpp> #include <com/sun/star/ucb/XCommandEnvironment.hpp> +#include <com/sun/star/security/XCertificate.hpp> #include <com/sun/star/task/XInteractionHandler.hpp> #include <com/sun/star/embed/XStorage.hpp> #include <com/sun/star/beans/PropertyValue.hpp> @@ -262,7 +263,10 @@ public: const INetURLObject& aDest, const css::uno::Reference< css::ucb::XCommandEnvironment >& xComEnv ); - SAL_DLLPRIVATE bool SignContents_Impl( bool bScriptingContent, const OUString& aODFVersion, bool bHasValidDocumentSignature ); + SAL_DLLPRIVATE bool + SignContents_Impl(const css::uno::Reference<css::security::XCertificate> xCert, + bool bScriptingContent, const OUString& aODFVersion, + bool bHasValidDocumentSignature); // the following two methods must be used and make sense only during saving currently // TODO/LATER: in future the signature state should be controlled by the medium not by the document diff --git a/include/sfx2/objsh.hxx b/include/sfx2/objsh.hxx index a17583b31c01..7263e78bdcbc 100644 --- a/include/sfx2/objsh.hxx +++ b/include/sfx2/objsh.hxx @@ -359,6 +359,7 @@ public: // xmlsec05, check with SFX team SignatureState GetDocumentSignatureState(); void SignDocumentContent(); + void SignDocumentContent(css::uno::Reference<css::security::XCertificate> xCert); SignatureState GetScriptingSignatureState(); void SignScriptingContent(); DECL_LINK(SignDocumentHandler, Button*, void); @@ -741,7 +742,10 @@ public: const css::uno::Reference< css::security::XDocumentDigitalSignatures >& xSigner = css::uno::Reference< css::security::XDocumentDigitalSignatures >() ); - SAL_DLLPRIVATE void ImplSign( bool bScriptingContent = false ); + SAL_DLLPRIVATE void + ImplSign(const css::uno::Reference<css::security::XCertificate> xCert, + bool bScriptingContent = false); + SAL_DLLPRIVATE bool QuerySaveSizeExceededModules_Impl( const css::uno::Reference< css::task::XInteractionHandler >& xHandler ); SAL_DLLPRIVATE bool QueryAllowExoticFormat_Impl( const css::uno::Reference< css::task::XInteractionHandler >& xHandler, const OUString& rURL, |