Bug 474472 - MySQL doesn't support modern caching_sha2_password
Summary: MySQL doesn't support modern caching_sha2_password
Status: REPORTED
Alias: None
Product: digikam
Classification: Applications
Component: Bundle-Windows (other bugs)
Version First Reported In: 8.2.0
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
: 501453 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-09-13 05:38 UTC by Lucas Jandrew
Modified: 2025-04-11 18:13 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lucas Jandrew 2023-09-13 05:38:52 UTC
SUMMARY
Modern versions of MySQL starting with 8.0 default to using the `caching_sha2_password` plugin.

On my Ubuntu install using the AppImage build, this is working fine. On Windows, digikam fails to start with an error that it can't find the `caching_sha2_password` plugin. Likely needs an updated QMySQL driver

STEPS TO REPRODUCE
1. Install Digikam on Windows
2. Test settup up a connection to a MySQL 8 server using caching_sha2_password

OBSERVED RESULT
Error message received stating the caching_sha2_password module cannot be found

EXPECTED RESULT
It successfully connects

SOFTWARE/OS VERSIONS
Windows: 11
Qt Version: Unknown

ADDITIONAL INFORMATION
Comment 1 caulier.gilles 2023-09-13 05:54:09 UTC
This will require to recompile whole MXE environnement to build Windows installer.

Note : the MSVC Windows bundle cannot used instead here, as MySQL support is not implemented in Qt With the Craft build system from KDE.

Gilles Caulier
Comment 2 caulier.gilles 2023-09-16 10:39:58 UTC
First attend to rebuild MXe from scratch with a more recent Qt5.

There is a failure to DejaVuLibre :

https://github.com/mxe/mxe/issues/3012

Gilles Caulier
Comment 3 caulier.gilles 2023-10-15 03:04:20 UTC
@Lucas Jandrew,


This problem still reproducible with the new digiKam 8.2.0 pre-release Windows
installer available at usual place:

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

This new bundle is based on last Qt framework 5.15.11 and KDE framework 5.110.

Thanks in advance

Dilles Caulier
Comment 4 caulier.gilles 2023-11-12 18:09:31 UTC
@Lucas Jandrew,

The digiKam 8.2.0 pre-release compiled under Windows 10 with VCPKG tool-chain is available here :

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

The next build planed tonight will include the mysql support. 

Please test with this version. Thanks in advance

Gilles Caulier
Comment 5 caulier.gilles 2023-11-21 15:38:24 UTC
@Lucas Jandrew,

The new digiKam 8.2.0 pre-release Windows installer is online. This one is built with VCPKG + MSVC toolchain and Qt6. It's a native version compiled under Windows 10. File is here:

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

Please test and report to see if problem remain.

Best regards

Gilles Caulier
Comment 6 Maik Qualmann 2023-12-11 20:17:33 UTC
Git commit 15a9beb0da4d6dd57862101cf1126bc7a058350a by Maik Qualmann.
Committed on 11/12/2023 at 21:15.
Pushed by mqualmann into branch 'master'.

disable SHA2 password for the internat MySQL server
Related: bug 478375

M  +1    -1    NEWS
M  +6    -1    core/data/database/mysql-global.conf

https://invent.kde.org/graphics/digikam/-/commit/15a9beb0da4d6dd57862101cf1126bc7a058350a
Comment 7 leo zhen 2025-03-11 05:30:55 UTC
showing again for digikam in macos (digiKam-8.5.0-Qt6-MacOS-arm64)
 when connecting to a MySQL 8.4.3 server

```
Database connection test was not successful. 
Error was: Plugin caching_sha2_password could not be loaded: dlopen(/opt/digikam.org.arm64/lib/mariadb-10.11/plugin/caching_sha2_password.so, 0x0002): tried: '/opt/digikam.org.arm64/lib/mariadb-10.11/plugin/caching_sha2_password.so' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/opt/digikam.org.arm64/lib/mariadb-10.11/plugin/caching_sha2_password.so' (no such file), '/opt/digikam.org.arm64/lib/mariadb-10.11/plugin/caching_sha2_password.so' (no such file) QMYSQL: Unable to connect
```
Comment 8 leo zhen 2025-03-12 00:55:01 UTC
Sorry for any disturbance when I changed the metadata of this issue. I thought it was a search filter
Comment 9 leo zhen 2025-03-12 01:16:41 UTC
(In reply to Maik Qualmann from comment #6)
> Git commit 15a9beb0da4d6dd57862101cf1126bc7a058350a by Maik Qualmann.
> Committed on 11/12/2023 at 21:15.
> Pushed by mqualmann into branch 'master'.
> 
> disable SHA2 password for the internat MySQL server
> Related: bug 478375
> 
> M  +1    -1    NEWS
> M  +6    -1    core/data/database/mysql-global.conf
> 
> https://invent.kde.org/graphics/digikam/-/commit/
> 15a9beb0da4d6dd57862101cf1126bc7a058350a

for the remote mqSQL server usage, how shall we force to use mysql_native_password without change the remote server?
Comment 10 Maik Qualmann 2025-03-13 15:38:47 UTC
*** Bug 501453 has been marked as a duplicate of this bug. ***
Comment 11 caulier.gilles 2025-04-11 18:13:36 UTC
Hi,

The 8.7.0 pre-release Windows installer from today have been rebuilt from
scratch with Qt 6.8.3, KDE 6.12, OpenCV 4.11 + CUDA support, Exiv2 0.28.5, ExifTool 13.27, ffmpeg 7, all image codecs updated to last version (jxl, avif, heif, aom, etc.).

Please try with this version to see if your problem still reproducible...

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

Thanks in advance
Best regards

Gilles Caulier