Description: The test files (binaries) for IMA and system events contain little endian integers which are assigned to the big endian integers with memcpy. The conversion has to be fixed. Author: Lukas Märdian Bug: https://github.com/tpm2-software/tpm2-tss/issues/2531 Bug-Ubuntu: https://bugs.launchpad.net/bugs/2031020 Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1040521 Forwarded: not-needed Last-Update: 2023-08-22 --- Index: tpm2-tss/test/unit/fapi-ima-eventlog.c =================================================================== --- tpm2-tss.orig/test/unit/fapi-ima-eventlog.c +++ tpm2-tss/test/unit/fapi-ima-eventlog.c @@ -8,6 +8,7 @@ #include #endif +#include #include #include #include @@ -259,11 +260,13 @@ int main(int argc, char *argv[]) { const struct CMUnitTest tests[] = { +# if __BYTE_ORDER == __LITTLE_ENDIAN cmocka_unit_test(check_invalidate_event), cmocka_unit_test(check_get_name), cmocka_unit_test(check_sml_ima_sha1), cmocka_unit_test(check_sml_ima_ng_sha1), cmocka_unit_test(check_sml_ima_sig_sha256), +# endif }; return cmocka_run_group_tests(tests, NULL, NULL); }