Skip to content

Linux app fails to communicate on Fedora 41 #3801

@Withalion

Description

@Withalion

After moving to Qt 6.8.3 the linux app fails on Fedora 41. CMake & Build passes without issues, but app can't find OpenSSL during runtime and all communications are failing.

I get mixture of these errors:

qt.network.ssl: The backend "cert-only" does not support QSslKey
qt.network.ssl: Active TLS backend does not support key creation
qt.network.ssl: QSslSocket::connectToHostEncrypted: TLS initialization failed

When trying to get some more debug info from Qt I got this:

  qDebug() << "Version: " << QSslSocket::sslLibraryVersionString();
  qDebug() << "Version build: " << QSslSocket::sslLibraryBuildVersionString();
  qDebug() << "Supports: " << QSslSocket::supportsSsl();
  qDebug() << "Backends: " << QSslSocket::availableBackends();
Version:  ""
Version build:  ""
Supports:  false
Backends:  QList("cert-only")

Quick-fix:
Change lookup locations for openssl in cmake/FindOpenSSL.cmake to system location.

find_path(
  OpenSSL_INCLUDE_DIR
  openssl/ssl.h
  "/usr/include"
  NO_DEFAULT_PATH
)

find_library(
  OpenSSL_CRYPTO_LIBRARY
  NAMES crypto libcrypto
  PATHS "/usr/lib"
  NO_DEFAULT_PATH
)

find_library(
  OpenSSL_LIBRARY
  NAMES ssl libssl
  PATHS "/usr/lib"
  NO_DEFAULT_PATH
)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions