spamassassin-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David B Funk <>
Subject Re: SPF weirdness...
Date Wed, 16 Jan 2019 03:02:27 GMT
On Tue, 15 Jan 2019, Bill Cole wrote:

> On 15 Jan 2019, at 15:05, Grant Taylor wrote:
>> I will investigate to see if spamass-milter can fabricate a satisfactory Received:
> A quick look at the issue tracker for it implies that it does so. A milter that actually
works with SA really needs to.
> Unfortunately, it is a nuisance to debug spamass-milter because it talks to spamc which
talks to spamd, so you need to give debug flags to the spamass-milter process and spamd to
see exactly what's going on.

This is a very real question.
It's a bit tricky to implement a milter correctly because people often don't 
understand that the message which sendmail hands to a milter is as-received 
from the incoming network connection.
Any locally added stuff (EG the "Received:" header) isn't in that milter stream.
Thus the milter must completely/correctly synthesize all locally added headers.

Actually the spamass-milter method (calling spamc) makes it easier to debug.
Just create a script which wraps spamc in-between a couple of "tee"s to capture 
stdin & stdout and you'll have everything you want to know.

A simple example which ignores signal handling:

  # 'spamc' debugging script
  echo "spamc args: $*" "" > ${FILE_NAME}.in
  tee -a ${FILE_NAME}.in | /real/path/to/spamc "$@" | tee ${FILE_NAME}.out

Adjust paths as needed.

Dave Funk                                  University of Iowa
<dbfunk (at)>        College of Engineering
319/335-5751   FAX: 319/384-0549           1256 Seamans Center
Sys_admin/Postmaster/cell_admin            Iowa City, IA 52242-1527
#include <std_disclaimer.h>
Better is not better, 'standard' is better. B{

View raw message