However, the exim4 code in bionic predates this refactor, and running_in_test_harness is a simple global.
Patch 0051-CVE-2020-28007-Link-attack-in-Exim-s-log-directory.patch adds code that assumes the f global exists:
+/* Write the contents to the history file */
+DEBUG(D_receive)
+ debug_printf("DMARC logging history data for opendmarc reporting%s\n",
+ (host_checking || f.running_in_test_harness) ? " (not really)" : "");
+if (host_checking || f.running_in_test_harness)
+ {
+ DEBUG(D_receive)
+ debug_printf("DMARC history data for debugging:\n%s", history_buffer);
+ }
So yeah, the patch from comment #3 should be applied to patch 0051 (or added as a followup fixup patch). But this is only needed for bionic.
I am able to reproduce this on bionic, but not on focal or newer.
The issue appears to be that in newer code, a bitmask structure was introduced to hold various boolean settings in the application:
## globals.c temp_details = FALSE, in_test_ harness = FALSE,
struct global_flags f =
{
.acl_
...
.running_
...
};
However, the exim4 code in bionic predates this refactor, and running_ in_test_ harness is a simple global.
Patch 0051-CVE- 2020-28007- Link-attack- in-Exim- s-log-directory .patch adds code that assumes the f global exists:
+/* Write the contents to the history file */ in_test_ harness) ? " (not really)" : ""); in_test_ harness)
+DEBUG(D_receive)
+ debug_printf("DMARC logging history data for opendmarc reporting%s\n",
+ (host_checking || f.running_
+if (host_checking || f.running_
+ {
+ DEBUG(D_receive)
+ debug_printf("DMARC history data for debugging:\n%s", history_buffer);
+ }
So yeah, the patch from comment #3 should be applied to patch 0051 (or added as a followup fixup patch). But this is only needed for bionic.