I've got a file which 'file' reports as "lostmail: ASCII mail text, with very long lines".
As I posted here yesterday, fetchmail was choking on ill-formed headers, which research suggested was actually exim puking and fetchmail handling the situation...ungracefully (fetchmail should, and may? have the option to simply delete or bounce such mails). Research suggested a fix was to use procmail as an MDA directly, rather than exim (the local MTA). This should reduce load on the local box anyway as this bypasses a redundent Spamassassin pass. So I edited /etc/fetchmailrc and added the line 'with mda "/usr/bin/procmail". Of course, the problem is, that this procmail process runs as the user fetchmail is running as. Though I'm somewhat relieved I didn't lose 1107 messages, totalling 34 MiB, I'm not quite sure what to do with the resulting file. (BTW, the fix, I suppose, is to run a user-mode fetchmail process, not a system daemon). Mutt doesn't recognize it as any known mbox format. I believe it's largely what fetchmail receives. The format is: A line reading "Status: U" A "Return-Path:" header. Subsequent RFC 822 headers. Message body. Sample: Status: U Return-Path: <[EMAIL PROTECTED]> Received: from popd.ix.netcom.com [207.217.120.162] by localhost with POP3 (fetchmail-6.2.3) for [EMAIL PROTECTED] (single-drop); Wed, 20 Aug 2003 02:25:24 +0100 (BS T) Received: from azhg1483.com ([216.139.181.133]) by killdeer (EarthLink SMTP Server) with SMTP id 19Pf8U32y3NZFlr0 for <[EMAIL PROTECTED]>; Tue, 19 Aug 2003 15:39:53 -0700 (PDT) From: "MR GARY CUSUMA" <[EMAIL PROTECTED]> Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Date: Tue, 19 Aug 2003 23:40:14 +0100 Subject: URGENT AND CONFIDENTIAL X-Mailer: Microsoft Outlook Express 5.00.2919.6900 DM MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Message-Id: <[EMAIL PROTECTED]> FROM=3AGARY CUSUMA My question is: how can I wrangle this file into a format that's further processable? I've tried with mutt, formail simply spits out a single, somewhat large mail message (all 34 MiB ;-). Suggestions welcomed. Peace. -- Karsten M. Self <[EMAIL PROTECTED]> http://kmself.home.netcom.com/ What Part of "Gestalt" don't you understand? The golden rule of technical design: complexity is the enemy.
pgp00000.pgp
Description: PGP signature