Bug 460775

Summary: "TLS initialization failed" error whenever the app tries to download files.
Product: [Applications] digikam Reporter: Paul <pnsears>
Component: Bundle-WindowsAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: caulier.gilles, metzpinguin
Priority: NOR    
Version First Reported In: 7.8.0   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed In: 7.9.0
Sentry Crash Report:
Attachments: Screen shot

Description Paul 2022-10-20 17:05:40 UTC
Created attachment 153062 [details]
Screen shot

SGetting "TLS initialization failed" error whenever the app tries to download files.

Any operation (e.g. check for updates, download files for facial recognition) results in the above error.


STEPS TO REPRODUCE
1. Start digikam.exe
2. Because it never has downloaded some accessory files, it asks to do so on startup
3. The download fails because of above error

OBSERVED RESULT
Internet downloads do not work

EXPECTED RESULT
Get the files the app needs.

SOFTWARE/OS VERSIONS
Windows: Windows 7 Professional, SP1, fully updated
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: ??
KDE Frameworks Version:   5.96.0
Qt Version:    5.15.5 (built against 5.15.5)

ADDITIONAL INFORMATION
Have recently installed and un-installed a couple of other Photo Management systems, each of which might have dragged their own DLLs in to the system. I am also a developer and have have Visual Studio 2008, and a couple of other versions (2005, 2017)
Comment 1 Maik Qualmann 2022-10-20 17:37:21 UTC
It's time for a new current Windows version. Many services are currently transitioning to TLS-1.1 or TLS-1.2. This is no longer supported by Windows 7 without doing anything. You have to install it manually with manual changes to the registry.

German:
https://support.microsoft.com/de-de/topic/update-zum-aktivieren-von-tls-1-1-und-tls-1-2-als-sichere-standardprotokolle-in-winhttp-in-windows-c4bd73d2-31d7-761e-0178-11268bb10392

I can't easily access the English page, it always switches to German, you'll find it.

Maik




Maik
Comment 2 Maik Qualmann 2022-10-20 17:46:59 UTC
English:
https://support.microsoft.com/en-us/topic/update-to-enable-tls-1-1-and-tls-1-2-as-default-secure-protocols-in-winhttp-in-windows-c4bd73d2-31d7-761e-0178-11268bb10392

Another note, for Office 365, starting October 31, TLS-1.0 and even TLS-1.1 will be disabled. Then only TLS-1.2 remains for Windows7 and that is a matter of time, because the first services are already enforcing TLS-1.3. There will be no TLS-1.3 support for Windows 7.

Maik
Comment 3 Maik Qualmann 2022-10-20 19:22:01 UTC
Ok, tested Windows7 in a VM, the problem occurs despite the activation of TLS-1.2. On Windows10 no problems with digiKam-7.9.0. A test of the KDE server shows that only TLS-1.2 and TLS-1.3 are supported. Will be continued....

Maik
Comment 4 Paul 2022-10-21 01:37:38 UTC
Thank you for looking into this.

On my machine, Win7 SP1, I enabled TLS 1.0, 1.1, and 1.2 (also SSL 2.0 and 3.0) which were already installed and that did not change the result, FWIW.

Paul
Comment 5 caulier.gilles 2022-10-21 05:56:08 UTC
Maik,

As the online downloader use QNetworkAccessManager in background :

https://invent.kde.org/graphics/digikam/-/blob/master/core/libs/onlineversion/onlineversiondwnl.cpp#L71

...this dysfunction must be relevant of Qt dependencies while compilation.

Gilles
Comment 6 caulier.gilles 2022-10-21 06:00:12 UTC
Paul,

From you Windows 7 computer, can you download the updated Windows installer yourself with a web browser using this repository :

https://files.kde.org/digikam/

This is mostly the job of the online downloader in digiKam....

Gilles
Comment 7 Maik Qualmann 2022-10-21 07:58:29 UTC
The problem also exists when checking for online updates.
The digiKam-7.9.0 (or 7.8.0) Windows bundle has this problem on Windows7 but not on Windows10

The Nightly MSVC digiKam-8.0.0 Windows bundle also works on Windows7.

Maik
Comment 8 Paul 2022-10-21 15:34:39 UTC
Thank you.

I went to "https://files.kde.org/digikam/" and found the files necessary for facial recognition.

It seems that none of the features that access the internet (e.g. Donate...) do not work though. I think most of them are available on the kde and digikam web sites.

paul
Comment 9 Maik Qualmann 2022-10-25 17:22:13 UTC
Git commit 3ac2d55865cc871df25aac052911a89d387b3b44 by Maik Qualmann.
Committed on 25/10/2022 at 17:20.
Pushed by mqualmann into branch 'qt5-maintenance'.

for testing add a certificate loading function
The certificate is not currently included in the bundle.
Related: bug 459160

M  +12   -0    core/app/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/3ac2d55865cc871df25aac052911a89d387b3b44
Comment 10 Maik Qualmann 2022-10-30 08:14:20 UTC
Git commit ad89f21b01f594fe2b7c8f49e5ecefe3a1d9280f by Maik Qualmann.
Committed on 30/10/2022 at 08:13.
Pushed by mqualmann into branch 'qt5-maintenance'.

remove test function for loading certificates
Related: bug 459160

M  +0    -9    core/app/DigikamTarget.cmake
M  +0    -12   core/app/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/ad89f21b01f594fe2b7c8f49e5ecefe3a1d9280f
Comment 11 Maik Qualmann 2022-11-01 06:58:35 UTC
Problem is now fixed, the cause was libssl-3.0.3 which did not work correctly under Windows 7. A new digiKam-7.9.0 test bundle is available for download here:

https://files.kde.org/digikam/

Maik
Comment 12 Paul 2022-11-01 18:08:39 UTC
Hi,
I am happy to report that features that need to connect to the net now work.
Thanks to everyone involved.
I will use the Donate button next!

p.