diff options
author | Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> | 2023-12-07 13:30:51 +0100 |
---|---|---|
committer | Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> | 2023-12-07 18:59:20 +0100 |
commit | 8a2820193315e8f56a041153ca5578ce7bdcb832 (patch) | |
tree | 699721bb212923941f2b14cf0109d16fa8d550a9 /uui | |
parent | f47ad18cbac928d3ee2511fe4fb25ed61240feb0 (diff) |
tdf#158576 Require viewing the certificate
before adding it to the list of trusted certificates.
This prevents certificates from being thoughtlessly
added to the list of trusted certificates.
Change-Id: Ifd0273df39f13432ebad72f1289ede0e6e7a8d5c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160427
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
Diffstat (limited to 'uui')
-rw-r--r-- | uui/source/secmacrowarnings.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/uui/source/secmacrowarnings.cxx b/uui/source/secmacrowarnings.cxx index 9ecdc9afa1d9..6b4102632755 100644 --- a/uui/source/secmacrowarnings.cxx +++ b/uui/source/secmacrowarnings.cxx @@ -103,9 +103,15 @@ IMPL_LINK_NOARG(MacroWarning, ViewSignsBtnHdl, weld::Button&, void) { xD->setParentWindow(m_xDialog->GetXWindow()); if( mxCert.is() ) + { xD->showCertificate( mxCert ); + mxAlwaysTrustCB->set_sensitive(true); + } else if( mxStore.is() ) + { xD->showScriptingContentSignatures( mxStore, uno::Reference< io::XInputStream >() ); + mxAlwaysTrustCB->set_sensitive(true); + } } } @@ -147,6 +153,7 @@ void MacroWarning::InitControls() // show signature controls? if (mbShowSignatures) { + mxAlwaysTrustCB->set_sensitive(false); mxViewSignsBtn->connect_clicked(LINK(this, MacroWarning, ViewSignsBtnHdl)); mxViewSignsBtn->set_sensitive(false); |