An option you can try is to link the tls module of kamailio to the libssl static libs. I pushed a commit to tls Makefile to guide on such process:
* https://github.com/kamailio/kamailio/commit/3e7278f28c43b830a197e2f7b212ec6f...
I tested a bit myself on Xenial and the libssl.a and libcrypto.a from the deb package are not compiled with -fPIC, so I had to download and compile libssl myself in a folder. I used the most recent 1.0.2u version (debs install 1.0.2a).
The process should be like:
- in kamailio soruce code folder, after applying the commit referenced above, edit src/modules/tls/Makefile and set: ``` LIBSSL_STATIC = yes LIBSSL_STATIC_SRCLIB = yes ``` - download the sources of openssl v1.0.2u and place them in: ``` /usr/local/src/openssl ``` - compile the openssl with next commands (do not install, only compile): ``` ./config --shared
make ``` - go back to kamailio sources and compile/install
- the ldd on tls.so should not show any libssl/libcrypto, because they are part of the file now, like:
``` ldd src/modules/tls/tls.so linux-vdso.so.1 => (0x00007ffedfa9b000) libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fc8b94d4000) /lib64/ld-linux-x86-64.so.2 (0x00007fc8b9dbb000 ```
In this way, the system uses the default installed libssl, only Kamailio is using 1.0.2a.