Age | Commit message (Collapse) | Author | Files | Lines |
|
Make sure that our normal SAL_WARN() reporting is registered during the
xmlSecCheckVersionExt() invocation, just like it's registered during
other libxmlsec API calls.
(cherry picked from commit 099ab643f60efc5be6f151bff89651efd2da1fc9)
Change-Id: Ia19368b55dbae47974f48954f86b50e36d1462ff
Reviewed-on: https://gerrit.libreoffice.org/64626
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
(cherry picked from commit 975a1934994ab1e7e5f2ac890f00159c73546a61)
|
|
When initializing for the in-memory database (NSS_NoDB_Init) the
internal slot is read-only so a lot of actions (PK11_ImportCert)
fails. Instead of that we create a new cert/key database inside
the tmp directory and delete it on exit. This way there are no
limitations and all the actions perform as expected.
Change-Id: Iadec5dd8f3459be56ba57d077057eacf3e0797fc
Reviewed-on: https://gerrit.libreoffice.org/65765
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 87eec1b90b6ecd83455f09168430c23f73c25c86)
|
|
Reviewed-on: https://gerrit.libreoffice.org/65764
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit a8d51dc85627514ce7f983eb4e0514ef00f84b1e)
Change-Id: Iebf7add3dd937afb6dad07a10ecbe768c0a79d36
|
|
When determining if a file is an XML file for siging, we need to
read the manifest file to get an accurate detection. In case when
we were signing in the GUI the manifest file was read when the
storage was set. When we didn't sign over the GUI, the manifest
was never read: the code was only present in the GUI code -
"documentsignaturesdialog.cxx" so the detection was wrong and
isXML returned "true" for current.xml.
With this we move the manifest reading to DigitalSignatureManager,
where the manifest is read when needed.
Reviewed-on: https://gerrit.libreoffice.org/65600
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 49fcd3bbb30f93763fc5cb80fa6ac5cec5d00834)
Change-Id: If45a32af6410bc5f7c5afdb976b182bd69ab7d6b
|
|
Change-Id: Icc85d3ff747d7372968cf4a3f514f0d3b7f8647c
|
|
which benefits LOOL since we can delay creating the image until
we know the dpi setting of the display we are going to write to.
Achieved by
perl -pi -w -e "s/\bImage\s*\(\s*BitmapEx\s*\((\w+)\s*\)\s*\)/Image\(\1\)/g" $( git grep -lw "BitmapEx" )
followed by
git grep -nP '\bImage\s*\(\s*BitmapEx\s*\('
followed by commenting out the BitmapEx(OUString) constructor and seeing
what needed adjusting.
Change-Id: I3224e11937d720fa484b0d659d25673a9e809267
Reviewed-on: https://gerrit.libreoffice.org/64760
Tested-by: Jenkins
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/64860
Tested-by: Michael Meeks <michael.meeks@collabora.com>
|
|
Change-Id: I3558010129eaafdab94ca3f8a63abeda32318fbb
Reviewed-on: https://gerrit.libreoffice.org/64336
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit bb8c2b1cbf7a9eb56b1515f60a2aadbef24199a2)
|
|
Reviewed-on: https://gerrit.libreoffice.org/64294
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 40d52cfe3b64e6bac035caed825486546bba5280)
Change-Id: I4a43f1f33f73919f56150310e7d05244d81b7510
|
|
This was added in commit ebd1b95bb5f9235d1dba1b840fd746c9b53320d2
(INTEGRATION: CWS xmlsec08 (1.1.2); FILE ADDED; 2005-03-10) without any
real commit message to explain why this is necessary.
system-xmlsec (not containing this patch) works fine for our XML signing
purposes with software certificates, and just recently I learned that
even hardware-based certificates work fine without this patch, so it can
go away.
I assume this was a refactor to allow some new feature as a next step,
but that feature was never implemented.
Reviewed-on: https://gerrit.libreoffice.org/55296
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
(cherry picked from commit f06004c03bbd076767a570180b7fc239064713e6)
Conflicts:
external/xmlsec/UnpackedTarball_xmlsec.mk
Change-Id: I31639230483cd34b14b35fd41b4fcd8284476138
|
|
(e.g., see xmlSecNssPKIKeyDataAdoptKey called from xmlSecNssPKIAdoptKey in
workdir/UnpackedTarball/xmlsec/src/nss/pkikeys.c, which has
if (ctx->privkey) {
SECKEY_DestroyPrivateKey(ctx->privkey);
}
ctx->privkey = privkey;
to install the passed in new privkey as ctx->privkey, which is apparently
considered owned by ctx)
Presumably since ab7fabd8b116d16def53772720f19fad4dbd6366 "lok: update the test
for singing the document from LOK" changed the relevant test code,
CppunitTest_desktop_lib fails in ASan builds with
> ==16681==ERROR: AddressSanitizer: heap-use-after-free on address 0x61d001a914a8 at pc 0x7f2af9afdf33 bp 0x7ffd59d3ccb0 sp 0x7ffd59d3cca8
> READ of size 4 at 0x61d001a914a8 thread T0
> #0 in SECKEY_GetPrivateKeyType at workdir/UnpackedTarball/nss/nss/lib/cryptohi/seckey.c:1716:21 (instdir/program/libnss3.so +0x3c6f32)
> #1 in xmlSecNssPKIAdoptKey at workdir/UnpackedTarball/xmlsec/src/nss/pkikeys.c:208:19 (instdir/program/libxsec_xmlsec.so +0x4026bc)
> #2 in SecurityEnvironment_NssImpl::createKeysManager() at xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx:846:41 (instdir/program/libxsec_xmlsec.so +0x36a4ce)
> #3 in XMLSignature_NssImpl::validate(com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSignatureTemplate> const&, com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSecurityContext> const&) at xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx:231:56 (instdir/program/libxsec_xmlsec.so +0x3ca23e)
> #4 in non-virtual thunk to XMLSignature_NssImpl::validate(com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSignatureTemplate> const&, com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSecurityContext> const&) at xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx (instdir/program/libxsec_xmlsec.so +0x3cb1ca)
> #5 in SignatureVerifierImpl::startEngine(rtl::Reference<XMLSignatureTemplateImpl> const&) at xmlsecurity/source/framework/signatureverifierimpl.cxx:70:44 (instdir/program/libxmlsecurity.so +0x6da8a9)
> #6 in SignatureEngine::tryToPerform() at xmlsecurity/source/framework/signatureengine.cxx:112:9 (instdir/program/libxmlsecurity.so +0x6c9a4e)
> #7 in SecurityEngine::referenceResolved(int) at xmlsecurity/source/framework/securityengine.cxx:39:5 (instdir/program/libxmlsecurity.so +0x6ba84a)
> #8 in ElementCollector::doNotify() at xmlsecurity/source/framework/elementcollector.cxx:136:39 (instdir/program/libxmlsecurity.so +0x660853)
> #9 in ElementCollector::notifyListener() at xmlsecurity/source/framework/elementcollector.cxx:88:5 (instdir/program/libxmlsecurity.so +0x660006)
> #10 in BufferNode::elementCollectorNotify() at xmlsecurity/source/framework/buffernode.cxx:725:40 (instdir/program/libxmlsecurity.so +0x5fe591)
> #11 in BufferNode::setReceivedAll() at xmlsecurity/source/framework/buffernode.cxx:96:5 (instdir/program/libxmlsecurity.so +0x5fd61a)
> #12 in SAXEventKeeperImpl::endElement(rtl::OUString const&) at xmlsecurity/source/framework/saxeventkeeperimpl.cxx:1067:36 (instdir/program/libxmlsecurity.so +0x67694c)
> #13 in XSecParser::endElement(rtl::OUString const&) at xmlsecurity/source/helper/xsecparser.cxx:408:29 (instdir/program/libxmlsecurity.so +0x885bd6)
> #14 in (anonymous namespace)::SaxExpatParser_Impl::callbackEndElement(void*, char const*) at sax/source/expatwrap/sax_expat.cxx:731:9 (instdir/program/libexpwraplo.so +0x1a0817)
> #15 in (anonymous namespace)::call_callbackEndElement(void*, char const*) at sax/source/expatwrap/sax_expat.cxx:242:9 (instdir/program/libexpwraplo.so +0x199604)
> #16 in doContent at workdir/UnpackedTarball/expat/lib/xmlparse.c:2954:11 (instdir/program/libexpwraplo.so +0x32fdf9)
> #17 in contentProcessor at workdir/UnpackedTarball/expat/lib/xmlparse.c:2531:27 (instdir/program/libexpwraplo.so +0x319c93)
> #18 in doProlog at workdir/UnpackedTarball/expat/lib/xmlparse.c:4556:14 (instdir/program/libexpwraplo.so +0x313539)
> #19 in prologProcessor at workdir/UnpackedTarball/expat/lib/xmlparse.c:4270:10 (instdir/program/libexpwraplo.so +0x2ffcc8)
> #20 in XML_ParseBuffer at workdir/UnpackedTarball/expat/lib/xmlparse.c:1983:25 (instdir/program/libexpwraplo.so +0x2fafbf)
> #21 in (anonymous namespace)::SaxExpatParser_Impl::parse() at sax/source/expatwrap/sax_expat.cxx:654:27 (instdir/program/libexpwraplo.so +0x19a27e)
> #22 in (anonymous namespace)::SaxExpatParser::parseStream(com::sun::star::xml::sax::InputSource const&) at sax/source/expatwrap/sax_expat.cxx:484:14 (instdir/program/libexpwraplo.so +0x192774)
> #23 in XMLSignatureHelper::ReadAndVerifySignature(com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&) at xmlsecurity/source/helper/xmlsignaturehelper.cxx:278:18 (instdir/program/libxmlsecurity.so +0x7dd825)
> #24 in DocumentSignatureManager::read(bool, bool) at xmlsecurity/source/helper/documentsignaturemanager.cxx:549:31 (instdir/program/libxmlsecurity.so +0x743aaa)
> #25 in DocumentDigitalSignatures::signDocumentWithCertificate(com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&, com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XStream> const&) at xmlsecurity/source/component/documentdigitalsignatures.cxx:781:23 (instdir/program/libxmlsecurity.so +0x4855fc)
> #26 in SfxMedium::SignDocumentContentUsingCertificate(bool, com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&) at sfx2/source/doc/docfile.cxx:3709:42 (instdir/program/libsfxlo.so +0x3577abe)
> #27 in SfxObjectShell::SignDocumentContentUsingCertificate(com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&) at sfx2/source/doc/objserv.cxx:1659:38 (instdir/program/libsfxlo.so +0x37e1aab)
> #28 in doc_insertCertificate(_LibreOfficeKitDocument*, unsigned char const*, int, unsigned char const*, int) at desktop/source/lib/init.cxx:3690:26 (instdir/program/libsofficeapp.so +0x7a40af)
> #29 in DesktopLOKTest::testInsertCertificate() at desktop/qa/desktop_lib/test_desktop_lib.cxx:2322:24 (workdir/LinkTarget/CppunitTest/libtest_desktop_lib.so +0x187439)
>
> 0x61d001a914a8 is located 40 bytes inside of 2048-byte region [0x61d001a91480,0x61d001a91c80)
> freed by thread T0 here:
> #0 in free at /home/sbergman/github.com/llvm-project/llvm-project-20170507/compiler-rt/lib/asan/asan_malloc_linux.cc:124:3 (workdir/LinkTarget/Executable/cppunittester +0x4feda8)
> #1 in PR_Free at workdir/UnpackedTarball/nss/nspr/out/pr/src/malloc/../../../../pr/src/malloc/prmem.c:458:9 (instdir/program/libnspr4.so +0x12c5af)
> #2 in FreeArenaList at workdir/UnpackedTarball/nss/nspr/out/lib/ds/../../../lib/ds/plarena.c:195:9 (instdir/program/libplds4.so +0xcc36)
> #3 in PL_FreeArenaPool at workdir/UnpackedTarball/nss/nspr/out/lib/ds/../../../lib/ds/plarena.c:216:5 (instdir/program/libplds4.so +0xcd9d)
> #4 in PORT_FreeArena_Util at workdir/UnpackedTarball/nss/nss/lib/util/secport.c:383:9 (instdir/program/libnssutil3.so +0x103381)
> #5 in SECKEY_DestroyPrivateKey at workdir/UnpackedTarball/nss/nss/lib/cryptohi/seckey.c:250:13 (instdir/program/libnss3.so +0x3baa05)
> #6 in xmlSecNSSPKIKeyDataCtxFree at workdir/UnpackedTarball/xmlsec/src/nss/pkikeys.c:109:9 (instdir/program/libxsec_xmlsec.so +0x4093a3)
> #7 in xmlSecNssPKIKeyDataFinalize at workdir/UnpackedTarball/xmlsec/src/nss/pkikeys.c:99:5 (instdir/program/libxsec_xmlsec.so +0x417a61)
> #8 in xmlSecNssKeyDataRsaFinalize at workdir/UnpackedTarball/xmlsec/src/nss/pkikeys.c:1086:5 (instdir/program/libxsec_xmlsec.so +0x419214)
> #9 in xmlSecKeyDataDestroy at workdir/UnpackedTarball/xmlsec/src/keysdata.c:248:9 (instdir/program/libxsec_xmlsec.so +0x5213f4)
> #10 in xmlSecKeyEmpty at workdir/UnpackedTarball/xmlsec/src/keys.c:533:9 (instdir/program/libxsec_xmlsec.so +0x518026)
> #11 in xmlSecKeyDestroy at workdir/UnpackedTarball/xmlsec/src/keys.c:555:5 (instdir/program/libxsec_xmlsec.so +0x51838a)
> #12 in xmlSecPtrListEmpty at workdir/UnpackedTarball/xmlsec/src/list.c:149:17 (instdir/program/libxsec_xmlsec.so +0x54943a)
> #13 in xmlSecPtrListFinalize at workdir/UnpackedTarball/xmlsec/src/list.c:129:5 (instdir/program/libxsec_xmlsec.so +0x548b87)
> #14 in xmlSecSimpleKeysStoreFinalize at workdir/UnpackedTarball/xmlsec/src/keysmngr.c:663:5 (instdir/program/libxsec_xmlsec.so +0x5432b0)
> #15 in xmlSecKeyStoreDestroy at workdir/UnpackedTarball/xmlsec/src/keysmngr.c:274:9 (instdir/program/libxsec_xmlsec.so +0x53a03c)
> #16 in xmlSecNssKeysStoreFinalize at workdir/UnpackedTarball/xmlsec/src/nss/keysstore.c:276:5 (instdir/program/libxsec_xmlsec.so +0x485f76)
> #17 in xmlSecKeyStoreDestroy at workdir/UnpackedTarball/xmlsec/src/keysmngr.c:274:9 (instdir/program/libxsec_xmlsec.so +0x53a03c)
> #18 in xmlSecKeysMngrDestroy at workdir/UnpackedTarball/xmlsec/src/keysmngr.c:84:9 (instdir/program/libxsec_xmlsec.so +0x539a79)
> #19 in SecurityEnvironment_NssImpl::destroyKeysManager(_xmlSecKeysMngr*) at xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx:862:9 (instdir/program/libxsec_xmlsec.so +0x36a817)
> #20 in std::default_delete<_xmlSecKeysMngr>::operator()(_xmlSecKeysMngr*) at xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx:52:46 (instdir/program/libxsec_xmlsec.so +0x3cd05d)
> #21 in std::unique_ptr<_xmlSecKeysMngr, std::default_delete<_xmlSecKeysMngr> >::~unique_ptr() at /usr/lib/gcc/x86_64-redhat-linux/8/../../../../include/c++/8/bits/unique_ptr.h:274:4 (instdir/program/libxsec_xmlsec.so +0x3cc759)
> #22 in XMLSignature_NssImpl::generate(com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSignatureTemplate> const&, com::sun::star::uno::Reference<com::sun::star::xml::crypto::XSecurityEnvironment> const&) at xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx:173:1 (instdir/program/libxsec_xmlsec.so +0x3c8934)
> #23 in non-virtual thunk to XMLSignature_NssImpl::generate(com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSignatureTemplate> const&, com::sun::star::uno::Reference<com::sun::star::xml::crypto::XSecurityEnvironment> const&) at xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx (instdir/program/libxsec_xmlsec.so +0x3c8b9a)
> #24 in SignatureCreatorImpl::startEngine(rtl::Reference<XMLSignatureTemplateImpl> const&) at xmlsecurity/source/framework/signaturecreatorimpl.cxx:78:44 (instdir/program/libxmlsecurity.so +0x6be738)
> #25 in SignatureEngine::tryToPerform() at xmlsecurity/source/framework/signatureengine.cxx:112:9 (instdir/program/libxmlsecurity.so +0x6c9a4e)
> #26 in SecurityEngine::referenceResolved(int) at xmlsecurity/source/framework/securityengine.cxx:39:5 (instdir/program/libxmlsecurity.so +0x6ba84a)
> #27 in ElementCollector::doNotify() at xmlsecurity/source/framework/elementcollector.cxx:136:39 (instdir/program/libxmlsecurity.so +0x660853)
> #28 in ElementCollector::notifyListener() at xmlsecurity/source/framework/elementcollector.cxx:88:5 (instdir/program/libxmlsecurity.so +0x660006)
> #29 in BufferNode::elementCollectorNotify() at xmlsecurity/source/framework/buffernode.cxx:725:40 (instdir/program/libxmlsecurity.so +0x5fe591)
> #30 in BufferNode::setReceivedAll() at xmlsecurity/source/framework/buffernode.cxx:96:5 (instdir/program/libxmlsecurity.so +0x5fd61a)
> #31 in SAXEventKeeperImpl::endElement(rtl::OUString const&) at xmlsecurity/source/framework/saxeventkeeperimpl.cxx:1067:36 (instdir/program/libxmlsecurity.so +0x67694c)
> #32 in XSecController::exportSignature(com::sun::star::uno::Reference<com::sun::star::xml::sax::XDocumentHandler> const&, SignatureInformation const&, bool) at xmlsecurity/source/helper/xsecctl.cxx:916:23 (instdir/program/libxmlsecurity.so +0x868894)
> #33 in XSecController::WriteSignature(com::sun::star::uno::Reference<com::sun::star::xml::sax::XDocumentHandler> const&, bool) at xmlsecurity/source/helper/xsecsign.cxx:393:17 (instdir/program/libxmlsecurity.so +0x894df1)
> #34 in XMLSignatureHelper::CreateAndWriteSignature(com::sun::star::uno::Reference<com::sun::star::xml::sax::XDocumentHandler> const&, bool) at xmlsecurity/source/helper/xmlsignaturehelper.cxx:248:29 (instdir/program/libxmlsecurity.so +0x7dcebe)
> #35 in DocumentSignatureManager::add(com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&, com::sun::star::uno::Reference<com::sun::star::xml::crypto::XXMLSecurityContext> const&, rtl::OUString const&, int&, bool, rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::graphic::XGraphic> const&, com::sun::star::uno::Reference<com::sun::star::graphic::XGraphic> const&) at xmlsecurity/source/helper/documentsignaturemanager.cxx:422:27 (instdir/program/libxmlsecurity.so +0x74032e)
> #36 in DocumentDigitalSignatures::signDocumentWithCertificate(com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&, com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XStream> const&) at xmlsecurity/source/component/documentdigitalsignatures.cxx:777:39 (instdir/program/libxmlsecurity.so +0x48541a)
> #37 in SfxMedium::SignDocumentContentUsingCertificate(bool, com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&) at sfx2/source/doc/docfile.cxx:3709:42 (instdir/program/libsfxlo.so +0x3577abe)
> #38 in SfxObjectShell::SignDocumentContentUsingCertificate(com::sun::star::uno::Reference<com::sun::star::security::XCertificate> const&) at sfx2/source/doc/objserv.cxx:1659:38 (instdir/program/libsfxlo.so +0x37e1aab)
> #39 in doc_insertCertificate(_LibreOfficeKitDocument*, unsigned char const*, int, unsigned char const*, int) at desktop/source/lib/init.cxx:3690:26 (instdir/program/libsofficeapp.so +0x7a40af)
> #40 in DesktopLOKTest::testInsertCertificate() at desktop/qa/desktop_lib/test_desktop_lib.cxx:2322:24 (workdir/LinkTarget/CppunitTest/libtest_desktop_lib.so +0x187439)
>
> previously allocated by thread T0 here:
> #0 in __interceptor_malloc at /home/sbergman/github.com/llvm-project/llvm-project-20170507/compiler-rt/lib/asan/asan_malloc_linux.cc:146:3 (workdir/LinkTarget/Executable/cppunittester +0x4ff187)
> #1 in PR_Malloc at workdir/UnpackedTarball/nss/nspr/out/pr/src/malloc/../../../../pr/src/malloc/prmem.c:435:55 (instdir/program/libnspr4.so +0x12892c)
> #2 in PL_ArenaAllocate at workdir/UnpackedTarball/nss/nspr/out/lib/ds/../../../lib/ds/plarena.c:127:27 (instdir/program/libplds4.so +0x9c8f)
> #3 in PORT_ArenaAlloc_Util at workdir/UnpackedTarball/nss/nss/lib/util/secport.c:321:9 (instdir/program/libnssutil3.so +0x1028c3)
> #4 in PORT_ArenaZAlloc_Util at workdir/UnpackedTarball/nss/nss/lib/util/secport.c:342:9 (instdir/program/libnssutil3.so +0x10311f)
> #5 in PK11_MakePrivKey at workdir/UnpackedTarball/nss/nss/lib/pk11wrap/pk11akey.c:865:9 (instdir/program/libnss3.so +0x3f6529)
> #6 in PK11_ImportAndReturnPrivateKey at workdir/UnpackedTarball/nss/nss/lib/pk11wrap/pk11pk12.c:538:18 (instdir/program/libnss3.so +0x4ebcac)
> #7 in PK11_ImportPrivateKeyInfoAndReturnKey at workdir/UnpackedTarball/nss/nss/lib/pk11wrap/pk11pk12.c:645:10 (instdir/program/libnss3.so +0x4dea0c)
> #8 in PK11_ImportDERPrivateKeyInfoAndReturnKey at workdir/UnpackedTarball/nss/nss/lib/pk11wrap/pk11pk12.c:299:10 (instdir/program/libnss3.so +0x4ddba8)
> #9 in SecurityEnvironment_NssImpl::insertPrivateKey(com::sun::star::uno::Sequence<signed char> const&) at xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx:883:25 (instdir/program/libxsec_xmlsec.so +0x36ac38)
> #10 in SecurityEnvironment_NssImpl::createDERCertificateWithPrivateKey(com::sun::star::uno::Sequence<signed char> const&, com::sun::star::uno::Sequence<signed char> const&) at xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx:897:37 (instdir/program/libxsec_xmlsec.so +0x36afe6)
> #11 in non-virtual thunk to SecurityEnvironment_NssImpl::createDERCertificateWithPrivateKey(com::sun::star::uno::Sequence<signed char> const&, com::sun::star::uno::Sequence<signed char> const&) at xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx (instdir/program/libxsec_xmlsec.so +0x36b49a)
> #12 in doc_insertCertificate(_LibreOfficeKitDocument*, unsigned char const*, int, unsigned char const*, int) at desktop/source/lib/init.cxx:3685:41 (instdir/program/libsofficeapp.so +0x7a3ea3)
> #13 in DesktopLOKTest::testInsertCertificate() at desktop/qa/desktop_lib/test_desktop_lib.cxx:2322:24 (workdir/LinkTarget/CppunitTest/libtest_desktop_lib.so +0x187439)
Change-Id: Id54bdea78affbf3aa24a1e9bb565c46f48f512e6
Reviewed-on: https://gerrit.libreoffice.org/62914
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
(cherry picked from commit 23874f86dd51386d98ef8e3d06a1ece05463ed3c)
|
|
Also needed to extend XCertificateCreator with a new method
"addDERCertificateToTheDatabase".
Reviewed-on: https://gerrit.libreoffice.org/62273
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 08c3c504644ee978c2ec75ba083765b6ffddf08c)
Conflicts:
desktop/qa/desktop_lib/test_desktop_lib.cxx
xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
Change-Id: I7b4df65365893bd5a0628aeec30b3156584849fe
|
|
If importing the certificate and private key is done separately,
they don't associate with each other, so with this you can add
the private key to the certificate that it belongs to. If the
private key is set in this way, then getPrivateKey() call doesn't
look into the database but just returns the private key stored
in the member variable.
Additionally use CERT_DecodeCertFromPackage to import the DER
certificate from the imput as CERT_DecodeDERCertificate doesn't
import a complete certificate and doesn't add it into the
certificate database.
Change-Id: I29876030f167cc5fa6b887f9bfeb0b84622c751e
Reviewed-on: https://gerrit.libreoffice.org/62271
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 2286137c40a2abb26d36beb906962baffd779312)
|
|
Reviewed-on: https://gerrit.libreoffice.org/61914
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit ef2623b712d7417d8135279d654a16de2caf56fc)
Conflicts:
xmlsecurity/source/xmlsec/nss/securityenvironment_nssimpl.cxx
Change-Id: I28aa17e6c97494769185ed289836524064030f39
|
|
Change-Id: Ibfdf92712264ad37aafed53db0fe8e8c4fea4699
Reviewed-on: https://gerrit.libreoffice.org/61913
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit a113aff7add62da5f2f8ffe0be453af4b1b79866)
|
|
Change-Id: I8c6917c63bbdcf0d9bb2eb1c89745186feb263f8
Reviewed-on: https://gerrit.libreoffice.org/61781
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 2077c5e4e10a8254206945520f084e6216464d6a)
|
|
Reviewed-on: https://gerrit.libreoffice.org/54432
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
(cherry picked from commit 201321f648e82ecc610e7a3324a46248a19c1704)
Conflicts:
cui/source/dialogs/SignSignatureLineDialog.cxx
xmlsecurity/source/component/documentdigitalsignatures.cxx
xmlsecurity/source/helper/documentsignaturemanager.cxx
Change-Id: I483a3b7895cdcb10ef9d6dacf167ed0f8db7e723
|
|
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
|
|
Reviewed-on: https://gerrit.libreoffice.org/61779
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit f9acea526b9aeb3cf450cd7ee43bd969385865db)
Conflicts:
xmlsecurity/source/helper/documentsignaturemanager.cxx
Change-Id: Ife206ab29f2f8eaa2358f45e6bae2290d95fd4d6
|
|
Reviewed-on: https://gerrit.libreoffice.org/61778
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 40810c43c48b25385b487c0b79c4c466dbf36be7)
Conflicts:
xmlsecurity/source/component/documentdigitalsignatures.cxx
Change-Id: I92e392b315c9217b63db830dea1b2e91387b56c2
|
|
Reviewed-on: https://gerrit.libreoffice.org/61061
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 89a60912bba7ffd6f65ea99f4664f343c5025c95)
Reviewed-on: https://gerrit.libreoffice.org/61173
Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
Change-Id: I3a7ab7ec046a6bbff4b4a020e76356ffd454bab8
Reviewed-on: https://gerrit.libreoffice.org/62546
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit caa828920719240bcf0fb4b55ffb0fd6a5dd8b82)
|
|
https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_3.35_release_notes
NSS 3.35 and later will automatically migrate migrate profiles from the
old "dbm:" BDB format to the new "sql:" SQLite format.
The new format can be read by NSS 3.12 and later, which is old enough that
it can be assumed to be available.
However LibreOffice still shouldn't migrate the profile on its own:
LO typically uses a Mozilla Firefox or Thunderbird profile, and if it is
a system Firefox with system NSS libraries, then it's probably a bad
idea for LO to migrate the profile under Firefox's nose, particularly
considering the "partial migration" scenario if the profile is
password-protected.
Try to avoid this by checking if the profile is the old format and
explicitly using the "dbm:" prefix to prevent the migration.
Change-Id: I06480522f830ce74e2fb7bf79fee84ad80979b82
Reviewed-on: https://gerrit.libreoffice.org/58756
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
(cherry picked from commit 61688aa1abd9db9adbb8dc5d5aacc6269b21fd27)
Reviewed-on: https://gerrit.libreoffice.org/58974
(cherry picked from commit dc5474b2e2f361eec981c6955630dbb020442eae)
|
|
With OFFICE-3940 the loext markup got accepted for ODF1.3 (and
the redundant KeyInfo element removed). Make sure manifest parser
can import new markup.
Change-Id: Id3c88654e8e6e0e256cd68fbb43f1ef670849cf7
Reviewed-on: https://gerrit.libreoffice.org/56597
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit a7bf6488ebb544e1efaed0a1e53073df9cc2064d)
Reviewed-on: https://gerrit.libreoffice.org/56678
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
(cherry picked from commit dd9232a6b2bcd32c7279e1476445214c6bb9e417)
|
|
Swap the order of the default and custom callback registration, since
the order of lookup is now reversed since
<https://github.com/lsh123/xmlsec/commit/968646fb9b8428174a112fce2f08b1ec89d0ed97>.
Thanks Tomas Chvatal for reporting this.
(cherry picked from commit 576f899811a22e83b6fb6a120c8da303b1f4cac1)
xmlsecurity: check for the libxmlsec version runtime, not build-time
For the general benefit of --with-system-xmlsec usage scenarios (where
LO may be built against an old version of xmlsec and run against a new
one).
(cherry picked from commit bc4e43dd926bbe6f5315b5c372770ac8c7222177)
Change-Id: I60a347454701a679db4ccd8924a723a236d5edff
Reviewed-on: https://gerrit.libreoffice.org/55462
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
(cherry picked from commit 3d532502c9a17049bdd383a3d5c56005222331b7)
Reviewed-on: https://gerrit.libreoffice.org/55944
Tested-by: Jenkins
(cherry picked from commit 355a59a7d4b0c8f50823d4bf68f0cb0c985a2b79)
|
|
This squashes the following commits:
From f68929ac611fdda19c1ee413effc59d33aa5ef97 Mon Sep 17 00:00:00 2001
From: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Date: Fri, 9 Mar 2018 01:38:26 +0100
Subject: gpg4libre: fix failing gpg test due to over-long filenames
With long workdir path, gpg sometimes fails with 'gpg: can't connect
to the agent: File name too long' error.
WK recommends to create preferred socket dir under /run/user, needs
prepping though via gpgconf.
See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=84720
From d7ecf4a4e37a9eeffa2b40f9fe5a2e6a8f90c876 Mon Sep 17 00:00:00 2001
From: Rene Engelhard <rene@debian.org>
Date: Sun, 18 Mar 2018 11:25:41 +0100
Subject: properly check for gpgconf (and --create-socketdir) working
From d6ed1d415d36809d784af780231258ea0ee1024f Mon Sep 17 00:00:00 2001
From: Rene Engelhard <rene@debian.org>
Date: Sun, 18 Mar 2018 19:06:58 +0100
Subject: actually add GPGCONF to config_host.mk.in
From 7a95ee8d0badb2cbbd137a6e18af1bada35ae933 Mon Sep 17 00:00:00 2001
From: Rene Engelhard <rene@debian.org>
Date: Sun, 18 Mar 2018 19:26:45 +0100
Subject: actually add HAVE_GPGCONF_SOCKETDIR to config_host.mk.in...
From 5204a5145d8232ea0650144fb4756c38303ef06e Mon Sep 17 00:00:00 2001
From: Rene Engelhard <rene@debian.org>
Date: Sun, 18 Mar 2018 19:28:55 +0100
Subject: revert accidentially comitted local changes :(
From bc358d39ac985914160e8aaa23b29469470c032b Mon Sep 17 00:00:00 2001
From: Rene Engelhard <rene@debian.org>
Date: Sun, 18 Mar 2018 20:36:45 +0100
Subject: this is sh, not make...
Change-Id: I7880fd7eee57cedc19b72348b45f0c1389409fe6
Reviewed-on: https://gerrit.libreoffice.org/51521
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
(cherry picked from commit 74d438f716d9cef165c78f950d4c53a46c37503c)
|
|
This way, it is possible to have all the strings translated in dialogs even
when different users use different languages. [It was already possible
to have different languages previously, but not everything in the dialog has
switched - like the buttons at the bottom of the dialogs etc.]
Change-Id: I29a5ae6d31a370eec60397884200b684ec1bf5b9
Reviewed-on: https://gerrit.libreoffice.org/46417
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/46979
Tested-by: Jenkins <ci@libreoffice.org>
(cherry picked from commit 101a79cc4d13a1f566c1b97c1329813eb7c61bcf)
|
|
Change-Id: Ic2df4e402ce1e855fbf9d9f6d8a37e664d0110c7
(cherry picked from commit ebfa6465378f5048d499df729c36b36617f50d80)
|
|
PDFDocument::Tokenize() in the aKeyword == "obj" case allocates a
PDFObjectElement, stores it as an owning pointer inside rElements, and
also stores two non-owning references to it in m_aOffsetObjects and
m_aIDObjects. So make sure those 2 other containers are also cleared
then elements go away.
LO_TRACE="valgrind" bin/run pdfverify <sample>
doesn't report errors anymore after the fix.
Change-Id: Ie103de3e24a1080257a79e53b994e8536a9597bc
Reviewed-on: https://gerrit.libreoffice.org/50631
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
|
|
Amends commit 1c58b047d117bb087abc571b74c06cdf7499b1a0, seems we
need that now on Windows, too
Change-Id: Ia0c5e1e577a4f8dfe02b4d8eda0d220fa5e5f2a1
Reviewed-on: https://gerrit.libreoffice.org/50235
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit e2d8e2e0e2248de980f59af15e8b3472c8f56f70)
Reviewed-on: https://gerrit.libreoffice.org/50255
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
|
|
...by CppunitTest setting LD_LIBRARY_PATH to include instdir/program.
This causes the spawned gpg-agent to load instdir/program/libassuan.so.0
instead of /usr/... and fail with:
writev(2, [{iov_base="gpg-agent", iov_len=9}, {iov_base=": ",
iov_len=2}, {iov_base="relocation error", iov_len=16}, {iov_base=": ",
iov_len=2}, {iov_base="gpg-agent", iov_len=9}, {iov_base=": ",
iov_len=2}, {iov_base="symbol assuan_sock_set_system_ho"...,
iov_len=118}, {iov_base="", iov_len=0}, {iov_base="", iov_len=0},
{iov_base="\n", iov_len=1}], 10) = 159
The failure happens in the libreoffice-6-0 branch on Fedora 27, whereas
the master branch doesn't fail because it has a newer version of
libassuan that happens to provide the required symbol.
Fix this by applying the patch that was added for ASAN in
d15f042abd5a1093984a0c8380837145f38c4efc to clear LD_LIBRARY_PATH
always on Linux.
Change-Id: I6a5c7fdfdd32234f39a182581b03d79739880c11
Reviewed-on: https://gerrit.libreoffice.org/50056
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
(cherry picked from commit 81e4be9cd39f1ae794a96471bf48637312a0f781)
Reviewed-on: https://gerrit.libreoffice.org/50059
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...because external/gpgmepp spawns /usr/bin/gpgconf (and later on /usr/bin/ggp2,
/usr/bin/gpgsm) which all depend on libgpg-error.so.0, so due to CppunitTest's
LD_LIBRARY_PATH will pick up instdir/program/libgpg-error.so.0, which fails due
to
> /usr/bin/gpgconf: symbol lookup error: /data/sbergman/lo-san/core/instdir/program/libgpg-error.so.0: undefined symbol: __asan_option_detect_stack_use_after_return
The easiest fix appears to be, when running sanitizers on Linux, to hack
gpgmepp's _gpgme_io_spawn to set LD_LIBRARY_PATH back to its original state.
(When it was originally unset, it will now be set but null, but that should not
make a difference.) This requires EXTRA_ENV_VARS to be set earlier in
CppunitTest.mk, so setting LIBO_LD_PATH doesn't use the LD_LIBRARY_PATH value
set in gb_CppunitTest_CPPTESTPRECOMMAND.
The backtrace of the first, originally failing call to _gpgme_io_spawn during
CppunitTest_xmlsecurity_signing:
> #0 0x00007fffe1f354dc in _gpgme_io_spawn (path=0x1 <error: Cannot access memory at address 0x1>, argv=0x7ffff2fbd4e0, flags=0, fd_list=0x9, atfork=0x4e, atforkvalue=0x7ffff2fbd4e0, r_pid=0x7ffff2fbd4e0) at posix-io.c:433
> #1 0x00007fffe1f41971 in read_gpgconf_dirs (pgmname=0x6110002f8e00 "/usr/bin/gpgconf", components=0) at dirinfo.c:206
> #2 0x00007fffe1f3fa29 in get_gpgconf_item (what=12) at dirinfo.c:284
> #3 0x00007fffe1f4073e in _gpgme_get_default_gpg_name () at dirinfo.c:370
> #4 0x00007fffe1e87093 in engine_get_file_name (proto=GPGME_PROTOCOL_OpenPGP) at engine.c:79
> #5 0x00007fffe1e84e89 in gpgme_get_engine_info (info=0x7ffff2a06160) at engine.c:230
> #6 0x00007fffe1e845ef in gpgme_engine_check_version (proto=GPGME_PROTOCOL_OpenPGP) at engine.c:144
> #7 0x00007fffe634e7d9 in GpgME::checkEngine(GpgME::Protocol) (proto=GpgME::OpenPGP) at context.cpp:1610
> #8 0x00007fff8df3fd49 in SecurityEnvironmentGpg::SecurityEnvironmentGpg() (this=0x6060005825c0) at xmlsecurity/source/gpg/SecurityEnvironment.cxx:30
> #9 0x00007fff8df5755e in SEInitializerGpg::createSecurityContext(rtl::OUString const&) (this=0x606000582560) at xmlsecurity/source/gpg/SEInitializer.cxx:45
> #10 0x00007fff8df57bb3 in non-virtual thunk to SEInitializerGpg::createSecurityContext(rtl::OUString const&) () at include/rtl/stringutils.hxx:170
> #11 0x00007fffab66de90 in DocumentSignatureManager::init() (this=0x7ffff2fbb020) at xmlsecurity/source/helper/documentsignaturemanager.cxx:78
> #12 0x00007fffab498504 in DocumentDigitalSignatures::ImplVerifySignatures(com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&, DocumentSignatureMode) (this=0x6080001aaf20, rxStorage=uno::Reference to (OStorage *) 0x60d0003a4c48, xSignStream=empty uno::Reference, eMode=DocumentSignatureMode::Content) at xmlsecurity/source/component/documentdigitalsignatures.cxx:264
> #13 0x00007fffab497f8b in DocumentDigitalSignatures::verifyDocumentContentSignatures(com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&) (this=0x6080001aaf20, rxStorage=uno::Reference to (OStorage *) 0x60d0003a4c48, xSignInStream=empty uno::Reference) at xmlsecurity/source/component/documentdigitalsignatures.cxx:127
> #14 0x00007fffab49c35b in non-virtual thunk to DocumentDigitalSignatures::verifyDocumentContentSignatures(com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&) () at include/cppu/unotype.hxx:136
> #15 0x00007fffafc062a3 in SfxObjectShell::ImplAnalyzeSignature(bool, com::sun::star::uno::Reference<com::sun::star::security::XDocumentDigitalSignatures> const&) (this=0x61100021c7c0, bScriptingContent=false, xSigner=empty uno::Reference) at sfx2/source/doc/objserv.cxx:1293
> #16 0x00007fffafc074b1 in SfxObjectShell::ImplGetSignatureState(bool) (this=0x61100021c7c0, bScriptingContent=false) at sfx2/source/doc/objserv.cxx:1322
> #17 0x00007fffafc0383d in SfxObjectShell::GetDocumentSignatureState() (this=0x61100021c7c0) at sfx2/source/doc/objserv.cxx:1485
> #18 0x00007fffafbb323c in SfxObjectShell::CheckForBrokenDocSignatures_Impl() (this=0x61100021c7c0) at sfx2/source/doc/objmisc.cxx:981
> #19 0x00007fffafbb2da4 in SfxObjectShell::CheckSecurityOnLoading_Impl() (this=0x61100021c7c0) at sfx2/source/doc/objmisc.cxx:931
> #20 0x00007fffafbb95cf in SfxObjectShell::FinishedLoading(SfxLoadedFlags) (this=0x61100021c7c0, nFlags=SfxLoadedFlags::ALL) at sfx2/source/doc/objmisc.cxx:1079
> #21 0x00007fff716a9185 in SwDocShell::LoadingFinished() (this=0x61100021c7c0) at sw/source/uibase/app/docsh.cxx:1153
> #22 0x00007fff71759ada in SwDocShell::Load(SfxMedium&) (this=0x61100021c7c0, rMedium=...) at sw/source/uibase/app/docshini.cxx:581
> #23 0x00007fffafc2bd9a in SfxObjectShell::LoadOwnFormat(SfxMedium&) (this=0x61100021c7c0, rMedium=...) at sfx2/source/doc/objstor.cxx:2971
> #24 0x00007fffafc3128c in SfxObjectShell::DoLoad(SfxMedium*) (this=0x61100021c7c0, pMed=0x60300083dac0) at sfx2/source/doc/objstor.cxx:714
> #25 0x00007fffafdd88d8 in SfxBaseModel::load(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (this=0x6190000fb0b0, seqArguments=uno::Sequence of length 13 = {...}) at sfx2/source/doc/sfxbasemodel.cxx:1788
> #26 0x00007fffb049a98a in (anonymous namespace)::SfxFrameLoader_Impl::load(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&) (this=0x6060004aaec0, rArgs=uno::Sequence of length 11 = {...}, _rTargetFrame=uno::Reference to ((anonymous namespace)::Frame *) 0x6160000c63f0) at sfx2/source/view/frmload.cxx:693
> #27 0x00007fff82d6a7ee in framework::LoadEnv::impl_loadContent() (this=0x7ffff2fe3040) at framework/source/loadenv/loadenv.cxx:1105
> #28 0x00007fff82d5aa6b in framework::LoadEnv::startLoading() (this=0x7ffff2fe3040) at framework/source/loadenv/loadenv.cxx:374
> #29 0x00007fff82d56633 in framework::LoadEnv::loadComponentFromURL(com::sun::star::uno::Reference<com::sun::star::frame::XComponentLoader> const&, com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, rtl::OUString const&, rtl::OUString const&, int, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (xLoader=uno::Reference to (framework::Desktop *) 0x6160000153f8, xContext=uno::Reference to (cppu::ComponentContext *) 0x611000002b10, sURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt", sTarget="_default", nFlags=0, lArgs=uno::Sequence of length 2 = {...}) at framework/source/loadenv/loadenv.cxx:160
> #30 0x00007fff82ec93f0 in framework::Desktop::loadComponentFromURL(rtl::OUString const&, rtl::OUString const&, int, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (this=0x616000015380, sURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt", sTargetFrameName="_default", nSearchFlags=0, lArguments=uno::Sequence of length 2 = {...}) at framework/source/services/desktop.cxx:618
> #31 0x00007fff82ec95eb in non-virtual thunk to framework::Desktop::loadComponentFromURL(rtl::OUString const&, rtl::OUString const&, int, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) () at include/rtl/stringutils.hxx:170
> #32 0x00007fffabe3097d in unotest::MacrosTest::loadFromDesktop(rtl::OUString const&, rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (this=0x60c000035e48, rURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt", rDocService="com.sun.star.text.TextDocument", rExtraArgs=empty uno::Sequence) at unotest/source/cpp/macros_test.cxx:50
> #33 0x00007fffb2ba9d2a in SigningTest::createDoc(rtl::OUString const&) (this=0x60c000035e00, rURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt") at xmlsecurity/qa/unit/signing/signing.cxx:204
> #34 0x00007fffb2bd1532 in SigningTest::testODFGoodGPG() (this=0x60c000035e00) at xmlsecurity/qa/unit/signing/signing.cxx:690
> #35 0x00007fffb2c304fd in std::__invoke_impl<void, void (SigningTest::*&)(), SigningTest*&>(std::__invoke_memfun_deref, void (SigningTest::*&)(), SigningTest*&) (__f=@0x6030001f0480: (void (SigningTest::*)(SigningTest * const)) 0x7fffb2bd0d80 <SigningTest::testODFGoodGPG()>, __t=@0x6030001f0490: 0x60c000035e00) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/invoke.h:73
> #36 0x00007fffb2c300e0 in std::__invoke<void (SigningTest::*&)(), SigningTest*&>(void (SigningTest::*&)(), SigningTest*&) (__fn=@0x6030001f0480: (void (SigningTest::*)(SigningTest * const)) 0x7fffb2bd0d80 <SigningTest::testODFGoodGPG()>, __args=@0x6030001f0490: 0x60c000035e00) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/invoke.h:95
> #37 0x00007fffb2c2ff2f in std::_Bind<void (SigningTest::*(SigningTest*))()>::__call<void, , 0ul>(std::tuple<>&&, std::_Index_tuple<0ul>) (this=0x6030001f0480, __args=...) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/functional:467
> #38 0x00007fffb2c2fb23 in std::_Bind<void (SigningTest::*(SigningTest*))()>::operator()<, void>() (this=0x6030001f0480) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/functional:549
> #39 0x00007fffb2c2e8d1 in std::_Function_handler<void (), std::_Bind<void (SigningTest::*(SigningTest*))()> >::_M_invoke(std::_Any_data const&) (__functor=...) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/std_function.h:316
> #40 0x00007fffb2c30b1c in std::function<void ()>::operator()() const (this=0x608000083660) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/std_function.h:706
> #41 0x00007fffb2c2db41 in CppUnit::TestCaller<SigningTest>::runTest() (this=0x608000083620) at workdir/UnpackedTarball/cppunit/include/cppunit/TestCaller.h:175
> #42 0x00007ffff78fc159 in CppUnit::TestCaseMethodFunctor::operator()() const (this=0x7ffff2e9c0d0) at TestCase.cpp:32
> #43 0x00007fffdc3cc8e3 in (anonymous namespace)::Protector::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x602000019910, functor=...) at test/source/vclbootstrapprotector.cxx:48
> #44 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x6030002189e0) at ProtectorChain.cpp:20
> #45 0x00007fffe8938ab3 in (anonymous namespace)::Prot::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x6020000003f0, functor=...) at unotest/source/cpp/unobootstrapprotector/unobootstrapprotector.cxx:89
> #46 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x603000218a10) at ProtectorChain.cpp:20
> #47 0x00007fffebc1e492 in (anonymous namespace)::Prot::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x602000000250, functor=..., context=...) at unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx:63
> #48 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x603000218a40) at ProtectorChain.cpp:20
> #49 0x00007ffff7863084 in CppUnit::DefaultProtector::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x602000000150, functor=..., context=...) at DefaultProtector.cpp:15
> #50 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x603000218a70) at ProtectorChain.cpp:20
> #51 0x00007ffff78c68f5 in CppUnit::ProtectorChain::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x60b000000510, functor=..., context=...) at ProtectorChain.cpp:86
> #52 0x00007ffff795e259 in CppUnit::TestResult::protect(CppUnit::Functor const&, CppUnit::Test*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) (this=0x7ffff2f000a0, functor=..., test=0x608000083620, shortDescription="") at TestResult.cpp:182
> #53 0x00007ffff78fa785 in CppUnit::TestCase::run(CppUnit::TestResult*) (this=0x608000083620, result=0x7ffff2f000a0) at TestCase.cpp:91
> #54 0x00007ffff798c2fe in CppUnit::TestRunner::WrappingSuite::run(CppUnit::TestResult*) (this=0x608000081820, result=0x7ffff2f000a0) at TestRunner.cpp:47
> #55 0x00007ffff795ccdf in CppUnit::TestResult::runTest(CppUnit::Test*) (this=0x7ffff2f000a0, test=0x608000081820) at TestResult.cpp:149
> #56 0x00007ffff798d23f in CppUnit::TestRunner::run(CppUnit::TestResult&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) (this=0x7ffff2f4db00, controller=..., testPath="") at TestRunner.cpp:96
> #57 0x000000000052e3a9 in (anonymous namespace)::ProtectedFixtureFunctor::run() const (this=0x7ffff2f00350) at sal/cppunittester/cppunittester.cxx:319
> #58 0x000000000052ae38 in sal_main() () at sal/cppunittester/cppunittester.cxx:469
> #59 0x0000000000529e2c in main(int, char**) (argc=23, argv=0x7fffffff2798) at sal/cppunittester/cppunittester.cxx:376
Reviewed-on: https://gerrit.libreoffice.org/46249
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
(cherry picked from commit d15f042abd5a1093984a0c8380837145f38c4efc)
Make --disable-runtime-optimizations not fail when LIBO_LD_PATH is unset
...outside of CppunitTest_xmlsecurity_signing
(cherry picked from commit 1553cc326c5eb98b658e2202630ba0f0217c0ae4)
Change-Id: I386a3b316c78344c2449568894c0f03ba39b1bf0
Reviewed-on: https://gerrit.libreoffice.org/50058
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Jenkins <ci@libreoffice.org>
|
|
The roundtrip of the pdf image failed due to this.
(cherry picked from commit f58a16d5987c8e8c16580c514ce0c7b0895b4105)
Change-Id: I88a9657e242dd2659f9bf06233e5fcbfeb43ceb5
Reviewed-on: https://gerrit.libreoffice.org/48378
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
|
|
Change-Id: I90679472898648ccf0811c67c17f7bad41d4e347
Reviewed-on: https://gerrit.libreoffice.org/47984
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 03afd4b72431a0dc197891d41fb7bf2419858380)
Reviewed-on: https://gerrit.libreoffice.org/47994
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
This squashes the following commits from master:
gpg4libre: import PGP encryption manifest
Change-Id: Iadd7f8f1194299cb50907d8594114c89c668ebd0
gpg4libre: open encrypted files also via gpg
Change-Id: I1f626143e6c8443b4ad0c4fc5bdbd5ab8d56a451
tdf#114550 use 32 bit random session key for gpg encryption
Change-Id: I7303be71fd855aa454d07fcae04d7f42e3c9cd9c
tdf#114550 recognize sym key & init vec as valid f/ decrypt
Change-Id: Ie366f086a3c14d6b54b91b4edee8cfef1a42c44b
tdf#114550 don't use PBKDF2 in package for gpg encryption
Change-Id: Ic96b2193f8541bbd109795fb9c0212a0a10c7344
gpg4libre: add initial unit test for encryption
Change-Id: Id782dd865878ae7b8a60c7c80821b1370f6ac7e7
Change-Id: Id77b67a275bf91614ab62b65fdc69e4872247ffc
Reviewed-on: https://gerrit.libreoffice.org/47784
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
|
|
For signing, preselect the key in the list of available keys.
For encryption, when 'encrypt to self' bit is set, add user's key
to the list of keys to encryption.
Change-Id: I5bbfd0e2cc97b76c1304a2a345a51cf83bc5949e
Reviewed-on: https://gerrit.libreoffice.org/46694
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit ee40674b4c9343db5e69cd5118bdbcf8e6edad6d)
Reviewed-on: https://gerrit.libreoffice.org/46759
Tested-by: Jenkins <ci@libreoffice.org>
|
|
Since some GnuPG versions tend to litter the source tree with random
files otherwise.
Change-Id: I0302f73b216f2de4dafcb6adca81097ec9d87e8c
Reviewed-on: https://gerrit.libreoffice.org/46447
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 2816ac4ad01874203efdbf9961ca2c22cbd94a3c)
Reviewed-on: https://gerrit.libreoffice.org/46468
|
|
And disable unit tests otherwise
Change-Id: I32e1d8d2f8b0013d9cb43b78a55d23a1a29a8e8d
Reviewed-on: https://gerrit.libreoffice.org/46057
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 7886de305809e265cd2126d39912147131d3a004)
Reviewed-on: https://gerrit.libreoffice.org/46191
Reviewed-by: Rene Engelhard <rene@debian.org>
|
|
Change-Id: I6f085b67c3477f427bd1efd96db93cbb89e20647
Reviewed-on: https://gerrit.libreoffice.org/46050
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 1e71870034c9e180f856f51dc2c183d2a6ba9ccd)
Reviewed-on: https://gerrit.libreoffice.org/46069
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I50ea6e82f18f296ea24f6e0d0e0e2eb381a5e54b
Reviewed-on: https://gerrit.libreoffice.org/46052
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 6283cd07d44d9aeacffbedb99d23e4ee760c6eb6)
Reviewed-on: https://gerrit.libreoffice.org/46083
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
|
|
Change-Id: I58af9d38ea8d202d2bda64cdf45204646ac9fd29
(cherry picked from commit ed50a0a2ce51584fa3a8fba0094220a4bf25c650)
|
|
Change-Id: I6b32444bab6848e2b5ddec02fd949c71114a66b2
|
|
And pass down all necessary parameters everywhere
Change-Id: I152b9d84c0e35be9e5193a9a6f67de9fb86133b0
|
|
Change-Id: If93c06ad90d708b0fbaf476bda6fdb902bd77b1e
|
|
Since this requires a working gpg setup, limit to linux for the
moment. If you need to add signatures or redo them, run LibreOffice
from a shell with env var
GNUPGHOME=<core>/xmlsecurity/qa/unit/signing/data/ set.
For editing keys, gpg2 also accepts a
--homedir=<core>/xmlsecurity/qa/unit/signing/data/ option
Change-Id: I59e5b563098b19d05c8c2db32537241bc835fc80
Reviewed-on: https://gerrit.libreoffice.org/45950
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 6da58b0e842b81669e5076c2c00dddf67a5616e1)
|
|
user config now needs it to collect user's private GPG keys
Change-Id: Ia4ad4133b621160cf37281750cafa9f3c5c3c231
Reviewed-on: https://gerrit.libreoffice.org/45562
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 1c58b047d117bb087abc571b74c06cdf7499b1a0)
|
|
Also pull in config_lgpl.h in that case.
Squashed in is this fix, too:
android: fix gpgme build
No need to include config_lgpl.h when gpgme is disabled.
Change-Id: Iae4e56ee8023066581c562c66305875a0fe15f37
Reviewed-on: https://gerrit.libreoffice.org/45809
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit 5daa364922ba75442e2aa834095e9bef16d141d9)
Reviewed-on: https://gerrit.libreoffice.org/45836
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
|
|
Change-Id: I33e299277c53e8e2b8ab7e4cdf52d2487f90b51b
Reviewed-on: https://gerrit.libreoffice.org/45211
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: David Tardon <dtardon@redhat.com>
(cherry picked from commit 7c77ff5dd2d0573a56f8b59dc9113c23e0ea29c9)
Signed-off-by: David Tardon <dtardon@redhat.com>
|
|
Change-Id: If0c81f5095b61d41b90db2e596bf5905b15ab506
Reviewed-on: https://gerrit.libreoffice.org/45210
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: David Tardon <dtardon@redhat.com>
|
|
ODF allows text properties on hyperlinks directly, librevenge wants an
inner span instead.
Change-Id: I903045a688bf318e7ac7f8cac83bb4d537259969
Reviewed-on: https://gerrit.libreoffice.org/45161
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
|
|
Change-Id: I1d139a7b6df271d61bedd107c6b3a0535d233606
Reviewed-on: https://gerrit.libreoffice.org/45124
Reviewed-by: Siegmund Gorr <siegmund.gorr@cib.de>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
|
|
Change-Id: Ibb83ef0bb6a304f2e78a669502a1bdd1f6dcc4bd
|