Commit 2c2f248
committed
xmlsec1: make crypto backend search relocatable
libltdl's lt_dlopenext() doesn't consult the calling binary's DT_RPATH
or DT_RUNPATH. When xmlsec1 is shipped under $OMD_ROOT, libltdl instead
finds the distro-installed /usr/lib/x86_64-linux-gnu/libxmlsec1-openssl
and loads that, hitting an ABI mismatch against the bundled 1.3.8.
We only get an error if there is a mismatch in versions of
libxmlsec1-openssl on some platforms this worked previously without
LD_LIBRARY_PATH being specified.
Patched xmlsec1's src/dl.c to use dladdr() on a libxmlsec1 data symbol
to locate libxmlsec1.so at runtime and register its directory via
lt_dladdsearchdir(). libxmlsec1.so is installed which is the same
directory that libxmlsec1-openssl.so is installed.
libxmlsec1.so is loaded normally so using RUNPATH on the binrary is fine
in this case.
Drop force_rpath=True from xmlsec1_deployable_bin: the misleading "RPATH
is required for dlopen()" comment was wrong for libltdl (which ignores
both RPATH and RUNPATH), so RUNPATH on the binary is sufficient for its
direct DT_NEEDED libs. Rewrite the BUILD comment accordingly.
Also fix the same copy-pasted comment on nagios_bin_runpath: there
force_rpath=True *is* justified, but for a different reason (DT_RPATH,
unlike DT_RUNPATH, is inherited when the loader resolves transitive
DT_NEEDED of dlopen()ed NEB modules).
CMK-33201
Change-Id: Ie429875d434998998fa939dba69e56e7eed76b04
(cherry picked from commit 08b6cca)1 parent 474adf2 commit 2c2f248
5 files changed
Lines changed: 84 additions & 5 deletions
File tree
- omd/packages
- nagios
- xmlsec1
- patches
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
414 | 414 | | |
415 | 415 | | |
416 | 416 | | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
417 | 422 | | |
418 | 423 | | |
419 | 424 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
69 | | - | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
70 | 74 | | |
71 | 75 | | |
72 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
33 | | - | |
34 | | - | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
35 | 37 | | |
36 | 38 | | |
37 | 39 | | |
| |||
Lines changed: 68 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
Whitespace-only changes.
0 commit comments