From 37da356e7b7ec11f486589dce4a230b36c53c7a3 Mon Sep 17 00:00:00 2001 From: Michal Klocek Date: Wed, 2 Nov 2022 17:08:44 +0100 Subject: Add client SSL authentication test MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Our qwebenginecertificatestore unit test so far only tested adding/removing custom certificates into the memory. However, it never actually initialized certificate store and did not test if ssl certificate client authentication really works. Cover that case and client authentication test. Note ca and client certificates in the test are self signed to be able to run test without network connection, however we ignore the errors. Pick-to: 6.4 Change-Id: I4df4fdfabed5abd8f8bde7d4c0c79b5fd7f6f3a9 Reviewed-by: Michael BrĂ¼ning --- tests/auto/quick/qmltests/tst_qmltests.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tests/auto/quick/qmltests') diff --git a/tests/auto/quick/qmltests/tst_qmltests.cpp b/tests/auto/quick/qmltests/tst_qmltests.cpp index bfa411416..0d9e12cd6 100644 --- a/tests/auto/quick/qmltests/tst_qmltests.cpp +++ b/tests/auto/quick/qmltests/tst_qmltests.cpp @@ -253,8 +253,9 @@ int main(int argc, char **argv) #if QT_CONFIG(ssl) qmlRegisterSingletonType( - "Test.Shared", 1, 0, "HttpsServer", - [&](QQmlEngine *, QJSEngine *) { return new HttpsServer(":/resources/server.pem",":/resources/server.key"); }); + "Test.Shared", 1, 0, "HttpsServer", [&](QQmlEngine *, QJSEngine *) { + return new HttpsServer(":/resources/server.pem", ":/resources/server.key", ""); + }); #endif Setup setup; int i = quick_test_main_with_setup( -- cgit v1.2.3