Subject: | SETSENDER uses outdated API and constant value |
Date: | Wed, 15 Jun 2016 13:27:39 -0400 |
To: | bug-Sendmail-PMilter [...] rt.cpan.org |
From: | "Jason Healy" <jhealy [...] suffieldacademy.org> |
The setsender() and SMFIR_SETSENDER values are incorrect in Context.pm, relative to currently-shipping Postfix and Sendmail.
Current definition is:
use constant SMFIR_SETSENDER => 's';
However, per the current Sendmail and Postfix sources, the action/reply is now known as SMFIR_CHGFROM ('change-from', not 'set-sender'). Additionally, the corresponding constant is 'e', not 's' ('s' is used for 'skip'):
http://fossies.org/linux/sendmail/include/libmilter/mfdef.h
https://github.com/vdukhovni/postfix/blob/master/postfix/src/milter/milter8.c
Likely should rename the function and constant to use the new nomenclature. However, as a quick fix, one can simply redefine the constant and the function works as intended:
use constant SMFIR_SETSENDER => 'e';
Jason