Age | Commit message (Collapse) | Author |
|
Change-Id: I54f0a47a4b7a1f85481fd1e643ac55459d0383ec
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93907
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Iff68e8f379614a6ab6a6e0d1bad18e70bc76d76a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91907
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
in unit tests
Change-Id: Id16731bbbe2f1b0e3642722d77aba04fc98db4cc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93508
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
to find places where we are converting stuff to unique_ptr
instead of using std::make_shared.
As a bonus, this tends to find places where we are using shared_ptr
where we can instead be using unique_ptr avoiding the locking overhead.
Change-Id: I1b57bbc4a6c766b48bba8e25a55161800e149f62
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93207
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
And format code inside
Change-Id: Ied0d98935134bf6f7bc8c929645ad5faac9affa3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93116
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
|
|
The problem was that the whole Subject info was returned from
X.509 certs if they did not start with one of "CN", "OU", "O", "E"
Instead of extending this list with random keys, pass the type of cert
and only return the whole Subject info if it's an OpenGPG one, and
process the info unconditionally if it's X.509 like before the OpenGPG
integration
Change-Id: I1aa5d7285e48b0f4a769a073cdfb7732e482792c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92675
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
|
|
... since b512ce255f46d90e682634e4dd17e146af7f9080.
Yes, MSVC also produces an error if the completeness requirements
are not met.
Change-Id: I0ad573ef1d14a383eed3a8f83aa932657c22ae20
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92963
Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
The main reason for the "home-grown" UpCast introduced with
904b3d1fceee5827076758ed2a81f80cb73493ca "Up-cast conversion constructor for
css::uno::Reference" in 2013 was probably that we could not yet rely on C++11
std::is_base_of back then. A (welcome) side effect was that the derived class
could be incomplete.
However, specializations of UpCast relying on whether or not T2 is incomplete
are obviously an ODR violation if the type is incomplete in some TUs and
complete (and derived from T1) in others. And even if UpCast had internal
linkage, it would still be brittle that its behavior depends on the completeness
of T2 at the point of the template's instantiation, and not necessarily at the
point of use.
That means we should better base that ctor on std::is_base_of (which we can do
now since 39a1edd6fec902ef378acce8af42c4d7fba280d0 "Make css::uno::Reference
upcast ctor LIBO_INTERNAL_ONLY"), which causes a compilation error at least on
Clang and GCC if the completeness requirements are not met. This change fixes
all the cases where types need to be complete now, plus any resulting
loplugin:referencecasting warnings ("the source reference is already a subtype
of the destination reference").
Change-Id: Ieb9e3552e90adbf2c5a5af933dcb872e20661a2f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92950
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I83a61da7dda6c72552eecd377f1c3744c92a797e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92909
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
and update pches accordingly
Change-Id: I411712532fd85961bffe6678416fcdc1d9c7f53d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92617
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
a particularly aggressive checker, which is why it is off by default
Change-Id: Id5a0faa50b3ecc75e01f4aedc6579c5209e585da
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91643
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I8e942bf37c9173a01bef6e1403ca21f579e7f608
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91612
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
This fixes structs size mismatch between xmlsec and its users because
of XMLSEC_NO_SIZE_T not yet defined at the time of their definition.
See https://lists.freedesktop.org/archives/libreoffice/2020-April/084800.html
Change-Id: I8de9a012f849d9a5a84f5ce580484b66192d1e06
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91531
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Do for xmlsecurity_pdfsigning what 5b66a038701241e0b9fa3a339acbd74f9ca4cf92
did for xmlsecurity_signing
Change-Id: I6a12c2c68db8dc1b9cdcaee0d3bf6372556ebd65
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91533
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
Change-Id: Id3d05de26ac9078a316de49ea2a5f6af26876107
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91507
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
Without this, running `make CppunitTest_xmlsecurity_signing` after
`make clean` will stop at "GpgME not installed correctly" dialogs,
because DocumentSignatureManager::init will try to initialize GPG
security context, which requires gpgme-w32spawn.exe to be present
in workdir/LinkTarget/Executable.
See also commit 0de0b8c9d80d68619b6f3c0e8d9429d8b08553fb.
Change-Id: I5d98e2e92a091e108f23d31fe0c8c8cf03faadcc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91488
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
|
|
Found by:
run-clang-tidy-10 -checks=-*,misc-unused-using-decls
Change-Id: I3e95791e223ef01e140a6217e29a9efae428a784
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90876
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Change-Id: I4897a6f2622e3e219f8b7b93d818d2edca03b117
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91008
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
As already stated in the comments of the signing unit tests,
disabling macro security will not only ignore the signatures, but
actually drop the macro signature, as these are never evaluated
and as a result can't be restored for the new document.
Change-Id: Ie41a9e72d3367c2eed58a52387bb67d8c41abff3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90435
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
|
|
GpgComponentFactory is unused since:
commit 06d7dbb3568889aa50f46d6307a39fa53a17313b
Date: Sun May 21 14:28:57 2017 +0200
gpg4libre: share static xmlsec lib between nss and gpg
tableautoformatfield.cxx should have been removed in:
commit 5990beed9aba690ea9487e2c4a64615b7504a0a1
Date: Fri Aug 29 16:37:43 2014 +0200
Dead code
xmlRow is unused since initial import
Change-Id: Ief186e9ef46238cc8cdb49f4adde52a45a98cbc4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89830
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
and
cid#1459027, cid#1459026, cid#1459025, cid#1459024, cid#1459021,
cid#1459018
Change-Id: If92e7665fcf947c5daf3094b9003e85c5c51f48f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89763
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: Ifa384933569b27d0d08eb479bb95b799163ae386
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88450
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I01253631be946fa4d113bb09e0ccb1945ef2ac18
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88328
Tested-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
To avoid duplication.
Change-Id: I0ee7c26d5d55bd868ead04c77e7f4ef2582f90e2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88138
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
This was causing generation of code in violation of clang-format
conformance in these files:
* xmlsecurity/inc/pch/precompiled_xsec_xmlsec.hxx
* connectivity/inc/pch/precompiled_ado.hxx
Also remove these 2 files from the clang-format blacklist.
Change-Id: I882028c0553a3ff7fb356611f498d50dea984a7f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88143
Tested-by: Jenkins
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
|
|
Change-Id: I9e2dbdfb8bbf5be4a74b1b581e742b3193b3756b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87496
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I4f6defffc7489ae95af3e2758327a26374795969
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87501
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
With --enable-pch=full there's not much difference between a "public"
header in <module>/inc and a private one in <module>/src/somewhere/inc .
And since the script searches recursively, this apparently helps to
find even more headers for lower pch levels.
Change-Id: I8483d0aa5b4fea5a59107c20a8aa5f1ef694af0a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87799
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
|
|
Change-Id: I82fa5528c879f288822fe9795d7d7da19f0abbee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87485
Tested-by: Jenkins
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
|
|
Change-Id: Iab35a8b85b3ba1df791c774f40b037f9420a071a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86708
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I0e792603435b7a1d9fcacf67a694ee8c4cc24a7b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87516
Tested-by: Jenkins
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
|
|
found by my new loplugin:unusedvariableplus
Change-Id: Ic3f55f492d43a53d8850a97d44059ff127fd69a2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87573
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
found by my new aggressive unused var plugin. these are unused return
values from function calls
Change-Id: I3359c583f535828f192cb833762dfedc008d82f0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87439
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Idcfa93ffe86112477ad81bcbf74b8e5b858423f2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87080
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
|
|
Change-Id: I7342275928e0231062f378942c567fe993b2a271
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86544
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Add support for macro and package signing with a provided certificate
which is already possible for document signing since LO 6.2:
boolean signScriptingContentWithCertificate(
[in] ::com::sun::star::security::XCertificate xCertificate,
[in] ::com::sun::star::embed::XStorage xStorage,
[in] ::com::sun::star::io::XStream xStream);
boolean signPackageWithCertificate(
[in] ::com::sun::star::security::XCertificate xCertificate,
[in] ::com::sun::star::embed::XStorage xStorage,
[in] ::com::sun::star::io::XStream xStream);
Change-Id: I9783cd317a7202691913be186eca95964b1e0ff7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86141
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
|
|
Change-Id: I061db162c44a7196c58f4ae6dae2f37c7ac9213a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86057
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I292d699ce1de10ca9341525161f5da2592102ff7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85778
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I1c2d0c418d2aa2198c82e89ce048851f30d07a7d
Reviewed-on: https://gerrit.libreoffice.org/85698
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I522c42d1fe97de2b1a8a629c97cf68e11006a328
Reviewed-on: https://gerrit.libreoffice.org/85327
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
* Don't hide the option dialogs "Macro security" push button.
I don't see any reason, why these settings should be hidden, if
macros are disabled or settings locked. At least a user can now
check, what is going on (still nothing shows disabled macros for
a document in the UI AFAIK).
* Don't scale the lock icons of the trusted list boxes.
This just uses the same alignments, which the macro security
level lock image uses, otherwise the image is scaled to fit the
whole space of its layout cell.
* Don't disable the trusted list boxes.
If the setting is locked, it's sufficient to disable all the
buttons, which allow modification (so View can stay enabled).
This way you can still scroll the list. Correct button handling
is already implemented and works for me.
* Catch exceptions of broken certificate data.
If your config contains certificates, which can't be correctly
decoded, the NSS backend will throw an exception, which kills
the dialog, but not the nested loop, resulting in a locked LO.
Also show an error dialog with the broken base64-encoded data.
Change-Id: I79002e0ce85cf9a9017caf858407f2f635a3a074
Reviewed-on: https://gerrit.libreoffice.org/85056
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
...plus loplugin:consttobool and loplugin:fakebool fallout
Change-Id: Ie3d8121815c080b13bea6d9deca1eb138ca56138
Reviewed-on: https://gerrit.libreoffice.org/84515
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...in preparation for wholesale replacement of boost::optional with
o3tl::optional, which will be an alias for either std::optional or
boost::optional, and std::optional only has value_or.
boost::optional::value_or was added with <https://github.com/boostorg/optional/
commit/3984c9f9a157ef116cea69bc8bb20f433320eb61> "Added function value_or()",
which according to git-describe first appeared in tag boost-1.56.0. We appear
to have no strict Boost baseline (the closest we get is with
> [AC_MSG_ERROR(boost/spirit/include/classic_core.hpp not found. install boost >= 1.36)]
in configure.ac), and at least CentOS 7 TDF machine tb76 only has
boost-devel-1.53.0-27.el7.x86_64. However, any environment using Xcode < 10
that needs to make o3tl::optional fall back to boost::optional should use
--without-system-boost, and external/boost is currently at 1.69.0, so should be
safe.
ATTENTION: In isolation, this commit will break in any environment that uses
Boost older than 1.56.0. It requires the following commit introducing
o3tl::optional. (But doing these changes in individual commits was deemed more
valuable than supporting a hypothetical future git-bisect against an old Boost.)
Change-Id: Ib31affa3eebf0d0029d8620dc6abb7a60f6c7629
Reviewed-on: https://gerrit.libreoffice.org/84127
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
improve the script to filter out more noise generated by library symbols
Change-Id: I22bf6037d56bc4015001825c3fb3b21a39d85e07
Reviewed-on: https://gerrit.libreoffice.org/84022
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I81fea38cd737a8be74e6ece333ca37cc434a1c33
Reviewed-on: https://gerrit.libreoffice.org/83765
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...following up on 314f15bff08b76bf96acf99141776ef64d2f1355 "Extend
loplugin:external to warn about enums".
Cases where free functions were moved into an unnamed namespace along with a
class, to not break ADL, are in:
filter/source/svg/svgexport.cxx
sc/source/filter/excel/xelink.cxx
sc/source/filter/excel/xilink.cxx
svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx
All other free functions mentioning moved classes appear to be harmless and not
give rise to (silent, even) ADL breakage. (One remaining TODO in
compilerplugins/clang/external.cxx is that derived classes are not covered by
computeAffectedTypes, even though they could also be affected by ADL-breakage---
but don't seem to be in any acutal case across the code base.)
For friend declarations using elaborate type specifiers, like
class C1 {};
class C2 { friend class C1; };
* If C2 (but not C1) is moved into an unnamed namespace, the friend declaration
must be changed to not use an elaborate type specifier (i.e., "friend C1;"; see
C++17 [namespace.memdef]/3: "If the name in a friend declaration is neither
qualified nor a template-id and the declaration is a function or an
elaborated-type-specifier, the lookup to determine whether the entity has been
previously declared shall not consider any scopes outside the innermost
enclosing namespace.")
* If C1 (but not C2) is moved into an unnamed namespace, the friend declaration
must be changed too, see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71882>
"elaborated-type-specifier friend not looked up in unnamed namespace".
Apart from that, to keep changes simple and mostly mechanical (which should help
avoid regressions), out-of-line definitions of class members have been left in
the enclosing (named) namespace. But explicit specializations of class
templates had to be moved into the unnamed namespace to appease
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92598> "explicit specialization of
template from unnamed namespace using unqualified-id in enclosing namespace".
Also, accompanying declarations (of e.g. typedefs or static variables) that
could arguably be moved into the unnamed namespace too have been left alone.
And in some cases, mention of affected types in blacklists in other loplugins
needed to be adapted.
And sc/qa/unit/mark_test.cxx uses a hack of including other .cxx, one of which
is sc/source/core/data/segmenttree.cxx where e.g. ScFlatUInt16SegmentsImpl is
not moved into an unnamed namespace (because it is declared in
sc/inc/segmenttree.hxx), but its base ScFlatSegmentsImpl is. GCC warns about
such combinations with enabled-by-default -Wsubobject-linkage, but "The compiler
doesn’t give this warning for types defined in the main .C file, as those are
unlikely to have multiple definitions."
(<https://gcc.gnu.org/onlinedocs/gcc-9.2.0/gcc/Warning-Options.html>) The
warned-about classes also don't have multiple definitions in the given test, so
disable the warning when including the .cxx.
Change-Id: Ib694094c0d8168be68f8fe90dfd0acbb66a3f1e4
Reviewed-on: https://gerrit.libreoffice.org/83239
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...plus follow-up loplugin:implicitboolconversion and loplugin:redundantcast
Change-Id: I9fc9c5cb46fbb50da87ff80af64cb0dfda3e5f90
Reviewed-on: https://gerrit.libreoffice.org/83207
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I95845d7217fc5e77e3f8e205030e9cd761ad0cc5
Reviewed-on: https://gerrit.libreoffice.org/82116
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ida35d27a4aaae1c137e3ed072dff62b7c7e894ca
Reviewed-on: https://gerrit.libreoffice.org/82399
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
|
|
Change-Id: Ice9a57eedb166672dbdfae6da2a172ab77566a19
Reviewed-on: https://gerrit.libreoffice.org/81983
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|