Files
nixpkgs/pkgs/development/libraries/tpm2-tss/no-dynamic-loader-path.patch
Markus Theil 86293d257e tpm2-tss: 4.1.3 -> 4.2.0
Bump due to security fixes:
https://github.com/tpm2-software/tpm2-tss/releases/tag/4.2.0

Adapted patches and removed already upstream ones.

Signed-off-by: Markus Theil <theil.markus@gmail.com>
2026-07-29 11:36:59 +02:00

482 lines
25 KiB
Diff

--- a/src/tss2-tcti/tctildr-dl.c
+++ b/src/tss2-tcti/tctildr-dl.c
@@ -84,14 +84,24 @@
const char *formats[] = {
/* <name> */
"%s",
+ /* <name> */
+ "@PREFIX@" "%s",
/* libtss2-tcti-<name>.so.0 */
FMT_TCTI_PREFIX "%s" FMT_LIB_SUFFIX_0,
+ /* libtss2-tcti-<name>.so.0 */
+ "@PREFIX@" FMT_TCTI_PREFIX "%s" FMT_LIB_SUFFIX_0,
/* libtss2-tcti-<name>.so */
FMT_TCTI_PREFIX "%s" FMT_LIB_SUFFIX,
+ /* libtss2-tcti-<name>.so */
+ "@PREFIX@" FMT_TCTI_PREFIX "%s" FMT_LIB_SUFFIX,
/* libtss2-<name>.so.0 */
FMT_TSS_PREFIX "%s" FMT_LIB_SUFFIX_0,
+ /* libtss2-<name>.so.0 */
+ "@PREFIX@" FMT_TSS_PREFIX "%s" FMT_LIB_SUFFIX_0,
/* libtss2-<name>.so */
FMT_TSS_PREFIX "%s" FMT_LIB_SUFFIX,
+ /* libtss2-<name>.so */
+ "@PREFIX@" FMT_TSS_PREFIX "%s" FMT_LIB_SUFFIX,
};
if (handle == NULL) {
--- a/test/unit/tctildr-dl.c
+++ b/test/unit/tctildr-dl.c
@@ -153,6 +153,9 @@
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_A);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_A);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_B);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
@@ -170,10 +173,16 @@
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_A);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_A);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_B);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_B);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_C);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
@@ -191,14 +200,23 @@
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_A);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_A);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_B);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_B);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_C);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_C);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_D);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
@@ -216,18 +234,30 @@
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_A);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_A);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_B);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_B);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_C);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_C);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_D);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" TEST_TCTI_TRY_D);
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, TEST_TCTI_TRY_E);
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
@@ -265,22 +295,37 @@
expect_string(__wrap_dlopen, filename, "libtss2-tcti-default.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-default.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-default.so.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-default.so.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-default.so.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-default.so.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-default.so.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-default.so.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-default.so.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-default.so.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-tabrmd.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
@@ -306,22 +351,37 @@
expect_string(__wrap_dlopen, filename, "libtss2-tcti-default.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-default.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-default.so.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-default.so.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-default.so.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-default.so.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-default.so.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-default.so.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-default.so.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-default.so.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-tabrmd.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
@@ -463,120 +523,225 @@
expect_string(__wrap_dlopen, filename, "libtss2-tcti-default.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-default.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-default.so.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-default.so.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-default.so.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-default.so.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-default.so.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-default.so.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-default.so.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-default.so.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
/* Skip over libtss2-tcti-tabrmd.so */
expect_string(__wrap_dlopen, filename, "libtss2-tcti-tabrmd.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-tabrmd.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-tabrmd.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-tabrmd.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-tabrmd.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-tabrmd.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-tabrmd.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-tabrmd.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-tabrmd.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-tabrmd.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
/* Skip over libtss2-tcti-device.so, /dev/tpmrm0 */
expect_string(__wrap_dlopen, filename, "libtss2-tcti-device.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-device.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-device.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-device.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-device.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-device.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-device.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-device.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-device.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-device.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
/* Skip over libtss2-tcti-device.so, /dev/tpm0 */
expect_string(__wrap_dlopen, filename, "libtss2-tcti-device.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-device.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-device.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-device.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-device.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-device.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-device.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-device.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-device.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-device.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
/* Skip over libtss2-tcti-device.so, /dev/tcm0 */
expect_string(__wrap_dlopen, filename, "libtss2-tcti-device.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-device.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-device.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-device.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-device.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-device.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-device.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-device.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-device.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-device.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
/* Skip over libtss2-tcti-swtpm.so */
expect_string(__wrap_dlopen, filename, "libtss2-tcti-swtpm.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-swtpm.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-swtpm.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-swtpm.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-swtpm.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-swtpm.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-swtpm.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-swtpm.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-swtpm.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-swtpm.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
/* Skip over libtss2-tcti-mssim.so */
expect_string(__wrap_dlopen, filename, "libtss2-tcti-mssim.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-mssim.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-mssim.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-mssim.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-libtss2-tcti-mssim.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-libtss2-tcti-mssim.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-mssim.so.0.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-mssim.so.0.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-libtss2-tcti-mssim.so.0.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-libtss2-tcti-mssim.so.0.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
TSS2_RC r;
TSS2_TCTI_CONTEXT *tcti;
@@ -597,18 +762,33 @@
expect_string(__wrap_dlopen, filename, "foo");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "foo");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-foo.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-foo.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-foo.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-foo.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-foo.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-foo.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-foo.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-foo.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
TSS2_RC rc = info_from_name("foo", &info, &data);
assert_int_equal(rc, TSS2_TCTI_RC_NOT_SUPPORTED);
@@ -719,18 +899,33 @@
expect_string(__wrap_dlopen, filename, "foo");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "foo");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-foo.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-foo.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-tcti-foo.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-tcti-foo.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-foo.so.0");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-foo.so.0");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
expect_string(__wrap_dlopen, filename, "libtss2-foo.so");
expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
will_return(__wrap_dlopen, NULL);
+ expect_string(__wrap_dlopen, filename, "@PREFIX@" "libtss2-foo.so");
+ expect_int_value(__wrap_dlopen, flags, RTLD_NOW);
+ will_return(__wrap_dlopen, NULL);
TSS2_RC rc = tctildr_get_info("foo", &info, &data);
assert_int_equal(rc, TSS2_TCTI_RC_NOT_SUPPORTED);