this is an old problem I run into several times and found also plenty of postings at googles, but this time I really want to know, who the evil is ;)
If I get a mail and pass it through procmail/formail to add an x-loop-header and then pass to deliver, deliver fails with an error: "Message contains invalid header" The reason is that formail (and not procmail !) - that always tries to fix the mail to be standardconform - adds one From-line at the beginning of the mail in a format deliver doesnt seem to like: example: cat /tmp/mail | formail -a"X-Loop3: "server.goldfisch.at" the input: Return-Path: <[EMAIL PROTECTED]> Received: from server2.local (localhost.localdomain [127.0.0.1])\\ by server2.local (8.12.1/8.12.1) with ESMTP id fATL5vOx015215 ... becomes to: >From [EMAIL PROTECTED] Mon Dec 3 01:29:04 2001 Return-Path: <[EMAIL PROTECTED]> Received: from server2.local (localhost.localdomain [127.0.0.1])\\ by server2.local (8.12.1/8.12.1) with ESMTP id fATL5vOx015215 ... While this is no current problem, cause I can use the -f switch of formail to prevent it from doing so or use the tail-command to remove this line again, I am worried about it, cause maybe one day a mail will pass by with the same format formails wants to make and deliver will fail ... who is wrong in this case ? formail or deliver ? thnx, peter ps: the proper solution at the moment will be to let formail add this suspicious first line in any case and remove it with tail later. While this is some unwanted overhead one should be on the save side doing so .. pps: well, the whole mail I tested is: Return-Path: <[EMAIL PROTECTED]> Received: from server2.local (localhost.localdomain [127.0.0.1]) by server2.local (8.12.1/8.12.1) with ESMTP id fATL5vOx015215 for <[EMAIL PROTECTED]>; Thu, 29 Nov 2001 22:05:57 +0100 Received: (from pilsl@localhost) by server2.local (8.12.1/8.12.1/Submit) id fATL5v58015212 for [EMAIL PROTECTED]; Thu, 29 Nov 2001 22:05:57 +0100 Date: Thu, 29 Nov 2001 22:05:57 +0100 From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: halllo Message-ID: <[EMAIL PROTECTED]> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.23i X-Loop3: server.ihf-hr.org kdlavsklvsksvdfkvs teste test test test -- mag. peter pilsl phone: +43 676 3574035 fax : +43 676 3546512 email: [EMAIL PROTECTED] sms : [EMAIL PROTECTED] pgp-key available