summaryrefslogtreecommitdiff
path: root/xmlsecurity
AgeCommit message (Collapse)AuthorFilesLines
2016-10-07filter: don't loose signing description during pdf exportMiklos Vajna2-2/+3
The free-form string attached to a signature is called description during ODF/OOXML signing. The certificate chooser dialog has an input field to provide that. The PDF export dialog's signature tab reuses this dialog, but also provides an an own reason input field for the same purpose. So in case the generic dialog's description field is filled, don't simply throw away that string, but set the pdf export's reason field to the same value. XDocumentDigitalSignatures.idl is not a published interface and it is used only internally, so the API change is only nominal. Change-Id: I6d4cf0b3f586417a76a052dc30c960478a95c984
2016-10-06drop unused STD_MASKCOLOR definesCaolán McNamara1-2/+0
Change-Id: I9e6d499788467e5215464cf8f5146721b847909c
2016-10-06I can't see any evidence of any remaining magenta mask using image resourcesCaolán McNamara1-1/+0
Change-Id: I12865d743daa3e6479edb60584d5bd01f88e818d
2016-10-05convert the last two lonely FixedInfos to FixedTextCaolán McNamara5-5/+0
Change-Id: Ia6ed5f71931a6141efb3d5e5eb329149d6850342
2016-10-05convert MapUnit to scoped enumNoel Grandin4-4/+4
I left a prefix on the names "Map" so that I would not have to re-arrange each name too much, since I can't start identifiers with digits like "100thMM" And remove RSC_EXTRAMAPUNIT, which doesn't seem to be doing anything anymore. Change-Id: I5187824aa87e30caf5357b51b5384b5ab919d224 Reviewed-on: https://gerrit.libreoffice.org/29096 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-10-05Remove _TYPED suffix from tools/link.hxx macrosStephan Bergmann11-54/+54
...which was introduced with 3ead3ad52f9bb2f9d1d6cf8dfc73a0a25e6778ed "Gradually typed Link" to distinguish the new, typed versions from the old, untyped ones, but is no longer necessary since 382eb1a23c390154619c385414bdbe6f6e461173 "remove untyped Link<>" removed the old versions. Change-Id: I494025df486a16a45861fcd8192dfe0275b1103c
2016-10-03Fix typosAndrea Gelmini1-1/+1
Change-Id: Iad27d1f87568890180c142774c238a14d022946d Reviewed-on: https://gerrit.libreoffice.org/29441 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-09-13loplugin:override: No more need for the "MSVC dtor override" workaroundStephan Bergmann32-39/+39
The issue of 362d4f0cd4e50111edfae9d30c90602c37ed65a2 "Explicitly mark overriding destructors as 'virtual'" appears to no longer be a problem with MSVC 2013. (The little change in the rewriting code of compilerplugins/clang/override.cxx was necessary to prevent an endless loop when adding "override" to OOO_DLLPUBLIC_CHARTTOOLS virtual ~CloseableLifeTimeManager(); in chart2/source/inc/LifeTime.hxx, getting stuck in the leading OOO_DLLPUBLIC_CHARTTOOLS macro. Can't remember what that isAtEndOfImmediateMacroExpansion thing was originally necessary for, anyway.) Change-Id: I534c634504d7216b9bb632c2775c04eaf27e927e
2016-08-29Indentation fixesMiklos Vajna1-1/+1
Change-Id: I903fcd36878cd0b74757805bcbdb414feb713d7b
2016-08-22Make CppunitTest_xmlsecurity_signing more reliableStephan Bergmann1-1/+2
...by placing cert8.db (and automatically created key3.db, secmod.db) in workdir/CppunitTest/xmlsecurity_signing.test.user/, which gets recreated afresh on every test run. (From solenv/gbuild/CppunitTest.mk, that path should be available in the test as the value of the UserInstallation bootstrap var, but then test::BootstrapFixtureBase::setUp in unotest/source/cpp/bootstrapfixturebase.cxx explicitly resets UserInstallation to someplace else.) Change-Id: Iebd2956134ec2226b28024e7c26e02b642a1e6b1
2016-08-18screenshots: add new global make targetArmin Le Grand1-1/+2
Up to now the screenshot creation was added/dependent of target slowcheck. Since quite some modules have added screenshot creations now, I added an own target 'screenshot' to allow to keep current slowcheck and screenshot creation separated Change-Id: I80a49a0db607edf8e0405672d570f624d29912e7
2016-08-18screenshots: unify dumping of dialog test batch fileArmin Le Grand1-74/+2
Change-Id: Ia1e79216d9537c65f8b7362778a2e1ad3ec6c2c2
2016-08-18screenshots: add dialog test cases for xmlsecurityArmin Le Grand4-0/+265
All *.ui files create a screenshot, but not all look useful Change-Id: I5ae156d76d4b0b53a8c5a9950afdbc42d8e66b73
2016-08-12loplugin:countusersofdefaultparams in vcl..xmlsecurityNoel Grandin1-1/+1
Change-Id: I538596a99e632178d928ff7e66ad45c71b73c6fd Reviewed-on: https://gerrit.libreoffice.org/28018 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-08-04tdf#100726 Improve readability of OUString concatanationsRosen1-4/+1
concat string to easy readability Change-Id: Ied5db1d74ad6266df558b859074257fd0049ad29 Reviewed-on: https://gerrit.libreoffice.org/27858 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-08-02libxmlsec: drop xmlsec1-keyinfo-revert.patch.1 completelyMiklos Vajna4-9/+11
And instead attempt to set up the test environment correctly. Change-Id: I06c10b96749c0464da8d2dd9a59b48f16baeead5 Reviewed-on: https://gerrit.libreoffice.org/27785 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-07-28Related: tdf#95144 now merge common code into a shared CertExtn structCaolán McNamara6-109/+91
Change-Id: I7514e092e4314d7cadee33df0e964362777b0b83
2016-07-28Related: tdf#95144 rework to avoid bad castsCaolán McNamara3-21/+73
Change-Id: I89f84dae055b9a1058771021cb42dbc442405206
2016-07-28Related: tdf#95144 Revert fixes for bad casts and unused fieldsCaolán McNamara3-28/+25
Revert "Bad cast from SanExtensionImpl to CertificateExtension_XmlSecImpl" This reverts commit 321b8ff86ba623b92aab5608eb94385e56823b65. Revert "loplugin:singlevalfields in writerfilter and xmlsec" This reverts commit a25327e4b18768e40c6044c86ce09136cfc23c10. cause these two together mean that we get a certificate is invalid dialog when the cert is perfectly fine on loading https sources Change-Id: Id8c1fb5ece4ecc0035500ce0b822a6b248d14282
2016-07-27improve passstuffbyref return analysisNoel Grandin2-2/+2
Change-Id: I4258bcc97273d8bb7a8c4879fac02a427f76e18c Reviewed-on: https://gerrit.libreoffice.org/27317 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-07-27loplugin:countusersofdefaultparams in tools..xmlsecurityNoel Grandin1-4/+4
find methods with default params with only zero or one call site Change-Id: Ie5b30f60e9fe00ba1acf0dfc79b005ded46f05a0 Reviewed-on: https://gerrit.libreoffice.org/27512 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-07-26masses of MessBoxes not being disposed promptlyCaolán McNamara2-2/+2
since... commit ba81e5c6bd420b41a84ade6ccd774011a8089f7f Date: Thu May 28 21:35:43 2015 +0100 tdf#91702 - fix stack-based MessBox allocation. There is no special ScopedVclPtr<X>::Create or ScopedVclPtrInstance<X>::Create just VclPtr<X>::Create and a raw VclPtr<X>::Create()->foo doesn't call dispose on the owned X Change-Id: Ifacc8d5e742820701307c3c37b9b86487667d84f
2016-07-13no need to create temporary OUString for comparisonNoel Grandin3-14/+14
Change-Id: I0a321e8ffbe379588a288084ec2e74e1a8c296b2 Reviewed-on: https://gerrit.libreoffice.org/27171 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-07-08Resolves: tdf#100452 class Date full (BCE,CE) proleptic Gregorian calendarEike Rathke1-4/+4
... implementing signed years with year 0 gap. Date(31,12,-1) last day BCE Date(1,1,1) first day CE New class Date member functions: * AddYears(sal_Int16) to be used instead of aDate.SetYear(aDate.GetYear()+sal_Int16) to handle year 0 gap. * convenience GetNextYear() to be used insted of GetYear()+1 * convenience GetPrevYear() to be used insted of GetYear()-1 * AddMonths(sal_Int32) * operator=(const css::util::Date&) New class DateTime member functions: * operator=(const css::util::DateTime&) Made some conversion ctors explicit, specifically Date(sal_Int32) Adapted hopefully all places that used a sal_uInt16 year to use sal_Int16 where appropriate. Eliminated some quirks in date handling found on the fly. Added era handling to i18npool icu calendar setting interface, which missing was responsible for 0001-01-01 entered in Calc being set as -0001-01-01, hence subtracting one day resulted in -0002-12-31. Change-Id: I77b39fba9599ebd5067d7864f6c9ebe01f6f578f Reviewed-on: https://gerrit.libreoffice.org/27049 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
2016-07-07loplugin:passstuffbyref also for {css::uno,rtl}::ReferenceStephan Bergmann2-2/+2
Change-Id: Ie6dd8317cb5add8a5072dd6aca2833d2d22b78d9
2016-07-06restore loplugin:vclwidget checking for calling clear() on VclPtr fieldsNoel Grandin1-0/+1
Change-Id: I85eda1c33016c1461d897fc0a3b70457209a7405 Reviewed-on: https://gerrit.libreoffice.org/26806 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-07-04Bad cast from SanExtensionImpl to CertificateExtension_XmlSecImplStephan Bergmann1-20/+26
...both ultimately derive from css::security::XCertificateExtension, but that is all they have in common. The special handling of 2.5.29.17 (and thus the bad casts) was introduced with d5feca7dcd9b2de4332c6b53657f6f5acbeb7b9a "tkr38: #i112307# Support for x509 v3 Subject Alternative Name extension added". Lets assume that it was an oversight there that setCertExtn (which is a function of CertificateExtension_XmlSecImpl, not inherited from a---common---base class) should not be called on such special-case SanExtensionImpl instances. Change-Id: I96cfd42f606c79920d1548f323b68f17ff4e9081
2016-07-04Certificate viewer dialog can have various kinds of parentsStephan Bergmann1-3/+5
...like the "Security Warning: Domain Name Mismatch" WarnDialog (cf. TITLE_UUI_SSLWARN_DOMAINMISMATCH in uui), not only a CertificateChooser. Regression introduced with c42be58e4c006ab3e1f262b644789cba8659d0ab "Show the certificate use also in the View Certificate dialog", for which this fix is hopefully fine. Change-Id: I6efced1ebaad07c314fe7a5dd1cdc8e91d34555e
2016-07-04Fix some spelling errors in comments and stringsOtto Kekäläinen1-3/+3
Change-Id: Iecd6b5e13d6be14651f77d8e37f01117ba15a11e Reviewed-on: https://gerrit.libreoffice.org/26883 Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-06-27loplugin:singlevalfields in writerfilter and xmlsecNoel Grandin2-5/+2
Change-Id: I51305ce4a6929b36f41eb7c7c83606ca8c5c89b8 Reviewed-on: https://gerrit.libreoffice.org/26691 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-13loplugin:sallogareasNoel Grandin9-20/+20
Change-Id: I6ce045db236b81aa8bc7bce2a0e20c4132c5931f
2016-06-13Convert DBG_ASSERT in xmlsecurityNoel Grandin9-19/+19
Change-Id: Ideec43617ff214b7e0dcbb0a1969955b34ee19e4 Reviewed-on: https://gerrit.libreoffice.org/26196 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-12convert DBG_ASSERT(false, to SAL_WARN(Noel Grandin2-2/+2
Change-Id: I400d728c5d99228c5ca52e369037395b4da2af5c Reviewed-on: https://gerrit.libreoffice.org/26187 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-09tdf#94698 cleanup Makefiles. Get rid of udkapi and offapiGleb Mishchenko1-4/+1
This patch changes occurences in makefiles from $(eval $(call gb_CppunitTest_use_api,comphelper_test_config, \ udkapi \ offapi \ )) to $(eval $(call gb_CppunitTest_use_sdk_api,comphelper_test_config)) (corrected instead of abandon, jani) Change-Id: Ic96ec65d82d7452e288f05a8b6d576ef543b068e Reviewed-on: https://gerrit.libreoffice.org/23426 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-06-06remove unused constants in HRC filesNoel Grandin4-32/+0
Change-Id: Ia034fb16ce75caeb69fd746d4a602cd5fcfef6d1 Reviewed-on: https://gerrit.libreoffice.org/25817 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-01Convert VCL_MESSAGE to scoped enumNoel Grandin2-2/+2
Change-Id: I976536849fa5585c96cee23b660c56d3d0116933 Reviewed-on: https://gerrit.libreoffice.org/25720 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-27Get rid of unnecessary directory levels $D/inc/$DTor Lillqvist45-92/+92
Change-Id: Ibf313b8948a493043006ebf3a8281487c1f67b48 Reviewed-on: https://gerrit.libreoffice.org/25532 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2016-05-25(nearly) nothing uses GetUniqueId anymore, so remove it.Caolán McNamara1-2/+0
The odd one out is the usage in Formula, which attempts to restore focus to a particular window identified by an unique id. In this case restore focus by keeping a VclPtr to the desired window. Change-Id: I1dc335325c109d75745c6bba2e12662e6ae50638
2016-05-20Show the certificate use also in the View Certificate dialogTor Lillqvist4-1/+13
Change-Id: I25ba55456be62307348eec529bfd434f8a90bac4
2016-05-20Add SAL_INFOs of the list of system and physical cert storesTor Lillqvist1-0/+70
Change-Id: I5c232e72c4a7fc18bc0f7ea29a9c912bf71284ba
2016-05-19loplugin:stringconstantTor Lillqvist1-1/+1
Change-Id: I30520ef862d5c925d1f5c236fb37aa719005bb49
2016-05-19Add column displaying intended usage to certificate chooserTor Lillqvist3-4/+97
The names for the KeyUsage bits defined in RFC3280 are stored in the .ui file for localisation Change-Id: Ia2cbfd28c8a5df6c94d4926fe98ea7048ff41dde
2016-05-19Make X509Certificate_MSCryptImpl::getCertificateUsage() actually workTor Lillqvist1-7/+26
According to MSDN, calling CryptDecodeObject() with X509_KEY_USAGE fills in a CRYPT_BIT_BLOB struct, not a CERT_KEY_USAGE_RESTRICTION_INFO one. Avoid potential complications of using CRYPT_DECODE_NOCOPY_FLAG. Instead, just follow the normal pattern of first finding out the size of buffer needed, allocate a such buffer, and then call the API again, passing that buffer. When called without CRYPT_DECODE_NOCOPY_FLAG, at least, it's what pbData points to that contains the usage bits, not the pointer value itself. Add SAL_WARNs for cleartext error messages in all error cases. Change-Id: I9b9f7d08d6013753d127c723dedd959109a85c97
2016-05-19clang-tidy misc-unused-alias-declsNoel Grandin4-5/+0
Change-Id: Iabde7a84b9c2758e0d2b2ffe0fb99fcfa51ff124 Reviewed-on: https://gerrit.libreoffice.org/25075 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-13clang-tidy modernize-loop-convert in writerfilter to xmlsecurityNoel Grandin2-9/+6
Change-Id: I334411c6b57c028ffb41b5deb72002f9d54038c3 Reviewed-on: https://gerrit.libreoffice.org/24923 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-29sw, xmlsecurity: indentation fixesMiklos Vajna1-2/+2
Change-Id: Iafb20132df4aba6b45cf49a7814084f66d087b25
2016-04-28Unit test for tdf#96097: Can't save/pointer nullGuillaume Smaha3-0/+111
Change-Id: I56af30142bba8579ca7f24bbbb2d12390832051b Reviewed-on: https://gerrit.libreoffice.org/24372 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org>
2016-04-22Avoid reserved identifierStephan Bergmann1-2/+2
Change-Id: I2577b4986f1b033253b368c570507e757893f98c
2016-04-20loplugin:salbool: Automatic rewrite of sal_False/TrueStephan Bergmann10-22/+22
Change-Id: I96cef821fc1d87963b8928af5dfc8ba97557da74
2016-04-18clang-tidy performance-unnecessary-copy-initializationNoel Grandin1-4/+3
probably not much performance benefit, but it sure is good at identifying leftover intermediate variables from previous refactorings. Change-Id: I3ce16fe496ac2733c1cb0a35f74c0fc9193cc657 Reviewed-on: https://gerrit.libreoffice.org/24026 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>