[Proposal] Consider supporting OpenSSL 3, which is the default OpenSSL library on newer distros
DarkmatterUAE opened this issue · 1 comments
I tried to setup a SimpleXMQ instance on a newly installed Debian 12 (bookworm) machine and was confused when it split out these error message:
root@debian:~# ./smp-server-ubuntu-20_04-x86-64 --help
./smp-server-ubuntu-20_04-x86-64: error while loading shared libraries: libcrypto.so.1.1: cannot open shared object file: No such file or directory
After a few digging, I found that file libcrypto.so.1.1
belongs to OpenSSL 1.1.1 shared library (package libssl1.1
), but Debian 12 only provides OpenSSL 3 shared library ( package libssl3
), which supplies libcrypto.so.3
.
Since OpenSSL 1.1 already reached EOL in Sept. 11th, 2023, many distros have migrated to OpenSSL 3, so I guess it's sensible to use OpenSSL 3 by default instead of OpenSSL 1.1.
As a desperate measure (and an extremely ugly hack), it's actually possible to use OpenSSL 3 library without installing libssl1.1
(not available in Debian bookworm by default, unless you add a source entry of Debian bullseye (11)), by soft-linking /usr/lib/x86_64-linux-gnu/libcrypto.so.1.1
to /usr/lib/x86_64-linux-gnu/libcrypto.so.3
, but apparantly no one should do that :)
root@debian:/usr/lib/x86_64-linux-gnu# ln -s libcrypto.so.3 libcrypto.so.1.1
root@debian:/usr/lib/x86_64-linux-gnu# ls -alh libcrypto*
lrwxrwxrwx 1 root root 14 May 30 13:19 libcrypto.so.1.1 -> libcrypto.so.3
-rw-r--r-- 1 root root 4.5M Oct 23 2023 libcrypto.so.3
root@debian:/usr/lib/x86_64-linux-gnu# cd
root@debian:~# ./smp-server-ubuntu-20_04-x86-64 --help
SMP server v5.7.5.0
Usage: smp-server-ubuntu-20_04-x86-64 [-v|--version] COMMAND
Available options:
-h,--help Show this help text
-v,--version Show version
Available commands:
init Initialize server - creates /etc/opt/simplex and
/var/opt/simplex directories and configuration files
cert Generate new online TLS server credentials
(configuration: /etc/opt/simplex/smp-server.ini)
start Start server (configuration:
/etc/opt/simplex/smp-server.ini)
delete Delete configuration and log files
Closing this issue due to SimpleX MQ project adding build target of Ubuntu 22.04, which uses OpenSSL 3 library. The problem mentioned in this issue has been solved.