[Pkg-exim4-users] Compiling Debian exim4 with dmarc support

ian-exim4 at zsd.co.za ian-exim4 at zsd.co.za
Tue May 10 13:10:30 BST 2022


Hi

I have been testing dmarc features on exim4. I compiled an 
exim4-daemon-custom_4.94.2-7~bpo10+1_amd64.deb package using on a 
"buster" system using the "buster-backports" version of exim4.

Now I have just upgraded the machine to "bullseye". I updated all of the 
packages, source files, and libraries but the compile breaks with this 
error:

/usr/include/opendmarc/dmarc.h:122:108: note: expected ‘int’ but 
argument is of type ‘unsigned char *’
   122 | OPENDMARC_STATUS_T opendmarc_policy_store_dkim(DMARC_POLICY_T 
*pctx, u_char *domain, u_char *selector, int result, u_char *human_result);
       | 
                                        ~~~~^~~~~~
dmarc.c:448:20: error: too few arguments to function 
‘opendmarc_policy_store_dkim’
   448 |     libdm_status = opendmarc_policy_store_dkim(dmarc_pctx, US 
sig->domain,
       |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from dmarc.h:14,
                  from exim.h:548,
                  from dmarc.c:14:
/usr/include/opendmarc/dmarc.h:122:20: note: declared here
   122 | OPENDMARC_STATUS_T opendmarc_policy_store_dkim(DMARC_POLICY_T 
*pctx, u_char *domain, u_char *selector, int result, u_char *human_result);
       |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~

After a bit of homework, it seems that there was a change in the API on 
the dmarc libraries which broke exim.

So I have a look at exim4_4.95-5 from testing. Looking through the 
sources I notice this in exim4-4.95/src/EDITME:

# Uncomment the following line to add DMARC checking capability, implemented
# using libopendmarc libraries. You must have SPF and DKIM support 
enabled also.
# Library version libopendmarc-1.4.1-1.fc33.x86_64  (on Fedora 33) is 
known broken;
# 1.3.2-3 works.  I seems that the OpenDMARC project broke their API.

If I try to run "make" on the testing version, it crashes with the same 
error.

What are the options, going forwards (or backwards), to fix this?

  * Is there a plan to fix this within Debian Exim, with a patch to make
    it compatible with the new API. Has a bug been filed on Debian Exim
    for this?
  * Is there a newer version of opendmarc libraries which will work?
  * Is it possible to pin these to an earlier version? What other issues
    will this cause?
      o libopendmarc2:amd64
      o libopendmarc-dev:amd64

I found this bug report from gentoo which show how they dealt with the 
issue:

https://bugs.gentoo.org/788343

Suggestions will be appreciated.

Thanks!

Ian




More information about the Pkg-exim4-users mailing list