Hi,
I have a greylisting policy daemon running with postfix v3.2.2. This
works nicely and when a mail is accepted, the policy daemon adds a
header along the lines of "X-greylist: mail greylisted for {duration} on
{hostname}."
This is done by sending "action=PREPEND header_text". This works nicely
as well.
Earlier today I noticed that due to a change of the hostname, the header
being added is now longer than 78 characters and is not folded according
to RFC2822 rules.
That is unexpected. I fiddled a bit with the code and tried to do the
folding in my policy daemon but was unsuccessful. A simple linebreak of
course is interpreted as an end-of-line marker for the policy delegation
protocol. And escaping the linebreak as \\n gives me a "\n" string in
the header of the resulting mail, but no linebreak...
I had a look at some other open source implementations of policy daemons
and it seems nobody has handled the case of long line headers.
Is there a good way of folding the header? Should postfix be doing that
automatically already?
cheers,
Andreas
- policyd, prepend and long lines Andreas Thienemann
-