Closed embeddeddev closed 10 months ago
Looks good I'll merge it later today
@embeddeddev The build process failed: buildx failed with: ERROR: failed to solve: process "/bin/sh -c cd /usr/lib/x86_64-linux-gnu && ln -s libcrypto.so.3 libcrypto.so" did not complete successfully: exit code: 2
Sorry, for the inconvenience. My fix addressed builds for linux/amd64 only. Don't know the status of the other platforms (armv7/arm64). Both at least the platform depending library directory differs for those and it's not testable out of the box for me.
This is also an workaround on debian/arm64 (RPI):
cd /usr/lib/aarch64-linux-gnu && ln -s libcrypto.so.3 libcrypto.so ; fi
So you should link to libcrypto.so.3
instead of libcrypto.so
?
To deconz-rest-plugin was added the feature to use install codes for pairing (e.g. used by Bosch Smart Home devices).
The docker for amd64 uses the Ubuntu deb package. This seems to be linked against
libcrypto.so
, whereas Debian docker base provides onlylibcrypto.so.3
library link.Unfortunately the code does not log any failure on library loading. After identification and test the problem was resolved by adding the required symlink
libcrypto.so -> libcrypto.so.3
to the Docker container.After that joining devices that require install codes works like a charm.
Method that adds install code support:
RestDevices::putDeviceInstallCode
(https://github.com/dresden-elektronik/deconz-rest-plugin/blob/master/rest_devices.cpp#L1029)Utility function that uses OpenSSL 3 crypto library w/o failure logging of missing library:
CRYPTO_GetMmoHashFromInstallCode
(https://github.com/dresden-elektronik/deconz-rest-plugin/blob/master/crypto/mmohash.cpp#L99)