summaryrefslogtreecommitdiff
path: root/xmlsecurity/qa
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2018-11-26 09:21:18 +0100
committerMiklos Vajna <vmiklos@collabora.com>2018-11-26 14:21:26 +0100
commit4a59a8aba8c9d451edff790d9281d0095c1bd78e (patch)
tree1fe2157cf457a5e43f53d14e4765b1b4b8fe30a7 /xmlsecurity/qa
parent12d0c06703842754de1eee4c1ea4f5796429730b (diff)
sfx2: show partial signatures even if cert validation fails
Change-Id: I6060b7130827346ac5d6955bf38ebe3b476819fd Reviewed-on: https://gerrit.libreoffice.org/64022 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'xmlsecurity/qa')
-rw-r--r--xmlsecurity/qa/unit/signing/signing.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/xmlsecurity/qa/unit/signing/signing.cxx b/xmlsecurity/qa/unit/signing/signing.cxx
index 411cfceecf82..d9507982486b 100644
--- a/xmlsecurity/qa/unit/signing/signing.cxx
+++ b/xmlsecurity/qa/unit/signing/signing.cxx
@@ -639,12 +639,14 @@ void SigningTest::testOOXMLPartial()
SfxObjectShell* pObjectShell = pBaseModel->GetObjectShell();
CPPUNIT_ASSERT(pObjectShell);
// This was SignatureState::BROKEN due to missing RelationshipTransform and SHA-256 support.
- // We expect NOTVALIDATED in case the root CA is not imported on the system, and PARTIAL_OK otherwise, so accept both.
+ // We expect NOTVALIDATED_PARTIAL_OK in case the root CA is not imported on the system, and PARTIAL_OK otherwise, so accept both.
+ // But reject NOTVALIDATED, hiding incompleteness is not OK.
SignatureState nActual = pObjectShell->GetDocumentSignatureState();
CPPUNIT_ASSERT_MESSAGE(
(OString::number(static_cast<std::underlying_type<SignatureState>::type>(nActual))
.getStr()),
- (nActual == SignatureState::NOTVALIDATED || nActual == SignatureState::PARTIAL_OK));
+ (nActual == SignatureState::NOTVALIDATED_PARTIAL_OK
+ || nActual == SignatureState::PARTIAL_OK));
}
void SigningTest::testOOXMLBroken()