On Thu, 30 Oct 2003, Matt Sergeant wrote:

> On 30 Oct 2003, at 11:02, Mark Powell wrote:
>
> >   I've been getting complaints from users of very long header lines. It
> > does seem that qpsmtpd is unfolding header lines, sometimes causing
> > rfc2822 non-complaince by created header lines over 998 chars in length
>
> Wow, observant users ;-)
>
> Try this patch - let me know if it works for you and I'll apply it. It
> folds at 80 chars, which is possibly a bit short, but fits nicely in a
> default terminal window.

That's maybe a fix, but why is this happening? In my admittedly short
experiments with Mail::Header I've always got the header lines back
exactly as they were before, unless I asked it to fold them. RFC2821 (as
you know) states that a relay must not modify existing Received: lines in
any way. All header lines in a message seem to be unfolded onto one line
currently, so isn't this going to kinda fix the problem, but make some
modification to existing Received: lines and thus violate RFC2821?
  I say all that without yet applying the patch so forgive me if I'm
talking out of my arse :(
  Cheers.

> Index: plugins/queue/qmail-queue
> ===================================================================
> RCS file: /cvs/public/qpsmtpd/plugins/queue/qmail-queue,v
> retrieving revision 1.5
> diff -u -r1.5 qmail-queue
> --- plugins/queue/qmail-queue   9 Oct 2003 17:21:49 -0000       1.5
> +++ plugins/queue/qmail-queue   30 Oct 2003 22:18:22 -0000
> @@ -55,6 +55,7 @@
>       close MESSAGE_READER  or fault("close msg reader fault"),exit;
>       close ENVELOPE_READER or fault("close envelope reader fault"),
> exit;
>
> +    $transaction->header->fold( 80 );
>       $transaction->header->print(\*MESSAGE_WRITER);
>       $transaction->body_resetpos;
>       while (my $line = $transaction->body_getline) {
>
>

-- 
Mark Powell - UNIX System Administrator - The University of Salford
Information Services Division, Clifford Whitworth Building,
Salford University, Manchester, M5 4WT, UK.
Tel: +44 161 295 4837  Fax: +44 161 295 5888  www.pgp.com for PGP key

Reply via email to