procmail
[Top] [All Lists]

Re: Cyrus and procmail

2008-07-21 15:25:16
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I just switched our company over to Cyrus pop/imap recently and I've found
an issue where procmail is not detecting the "From" header properly and
even in the log file, procmail is getting confused.

Good, you have logs. So, how come you didn't post excerpts, along with headers from a supoosedly misprocessed message, along with the recipe which failed to "detect" the From header?

The headers from your email:  :)

Return-Path: <cyrus(_at_)mail>
X-Spam-Checker-Version: SpamAssassin 3.1.7 (2006-10-05) on swebb.cluster
X-Spam-Level:
X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,UNPARSEABLE_RELAY
    autolearn=ham version=3.1.7
Received: from mail.pronto.com [66.235.125.216]
    by swebb.cluster with POP3 (fetchmail-6.3.4)
for <swebb(_at_)localhost> (single-drop); Mon, 21 Jul 2008 16:03:19 -0600 (MDT)
Received: from murder ([unix socket])
     (authenticated user=swebb bits=0)
     by mail (Cyrus v2.3.7-Invoca-RPM-2.3.7-1.1.el5) with LMTPA;
     Mon, 21 Jul 2008 16:03:07 -0600
X-Sieve: CMU Sieve 2.3
Received: from mta-2.ms.rz.rwth-aachen.de (mta-2.ms.rz.RWTH-Aachen.DE [134.130.7.73])
    (using TLSv1 with cipher RC4-MD5 (128/128 bits))
    (No client certificate requested)
    by mail.pronto.com (Postfix) with ESMTP id D05821B901C6
    for <swebb(_at_)pronto(_dot_)com>; Mon, 21 Jul 2008 16:03:07 -0600 (MDT)
Received: from ironport-out-1.rz.rwth-aachen.de ([134.130.3.58])
 by mta-2.ms.rz.RWTH-Aachen.de
 (Sun Java System Messaging Server 6.2-8.04 (built Feb 28 2007))
 with ESMTP id 
<0K4D00HWYML4PN40(_at_)mta-2(_dot_)ms(_dot_)rz(_dot_)RWTH-Aachen(_dot_)de> for
 swebb(_at_)pronto(_dot_)com; Tue, 22 Jul 2008 00:03:06 +0200 (CEST)
Received: from smarthost-1.ms.rz.rwth-aachen.de (HELO smarthost.rwth-aachen.de)
 ([134.130.7.89]) by ironport-in-1.rz.rwth-aachen.de with ESMTP; Tue,
 22 Jul 2008 00:02:55 +0200
Received: from iris.rz.RWTH-Aachen.DE (iris.rz.RWTH-Aachen.DE [134.130.4.37])
    by smarthost.rwth-aachen.de (8.13.8+Sun/8.13.8/1)
 with ESMTP id m6LM2swI001448; Tue, 22 Jul 2008 00:02:54 +0200 (CEST)
Received: from iris.rz.RWTH-Aachen.DE (localhost.localdomain [127.0.0.1])
by iris.rz.RWTH-Aachen.DE (8.13.8/8.13.8) with ESMTP id m6LM2qif008585; Tue,
 22 Jul 2008 00:02:54 +0200
Received: from mta-2.ms.rz.rwth-aachen.de
 (mta-2.ms.rz.RWTH-Aachen.DE    [134.130.7.73]) by iris.rz.RWTH-Aachen.DE
 (8.13.8/8.13.8) with ESMTP id m6LM1kjv008544   for
 <procmail(_at_)lists(_dot_)rwth-aachen(_dot_)de>; Tue, 22 Jul 2008 00:01:46 
+0200
Received: from ironport-out-1.rz.rwth-aachen.de ([134.130.3.58])
    by mta-2.ms.rz.RWTH-Aachen.de
    (Sun Java System Messaging Server 6.2-8.04 (built Feb 28 2007))
    with ESMTP id 
<0K4D00CN3MIYE470(_at_)mta-2(_dot_)ms(_dot_)rz(_dot_)RWTH-Aachen(_dot_)de> for
    procmail(_at_)lists(_dot_)rwth-aachen(_dot_)de; Tue, 22 Jul 2008 00:01:46 
+0200 (CEST)
Received: from trei.professional.org ([216.240.41.72])
    by mx5.rz.rwth-aachen.de with ESMTP; Tue, 22 Jul 2008 00:01:45 +0200
Received: from banshee.professional.org
    (banshee.professional.org [216.240.41.79])
by trei.professional.org (8.12.10/8.12.10) with ESMTP id m6LM1jra005989 for
    <procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE>; Mon, 21 Jul 2008 15:01:46 
-0700
Date: Mon, 21 Jul 2008 14:42:36 -0700
From: PSE-L(_at_)mail(_dot_)professional(_dot_)org (Professional Software 
Engineering)
Subject: Re: Cyrus and procmail
In-reply-to: 
<Pine(_dot_)LNX(_dot_)4(_dot_)64(_dot_)0807211451030(_dot_)4411(_at_)swebb(_dot_)cluster>
Sender: procmail-bounces(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
X-Sender:
To: procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
Errors-to: procmail-bounces(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
Reply-to: procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
Message-id: 
<5(_dot_)1(_dot_)1(_dot_)6(_dot_)2(_dot_)20080721143536(_dot_)08469ea0(_at_)smtp(_dot_)professional(_dot_)org>
Organization: Professional Software Engineering
MIME-version: 1.0
X-Mailer: QUALCOMM Windows Eudora Version 5.1.1
Content-type: text/plain; charset=iso-8859-1; Format=flowed
Content-transfer-encoding: 7BIT
Precedence: list
X-BeenThere: procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
X-IronPort-AV: E=Sophos;i="4.31,225,1215381600"; d="scan'208";a="76393937"
X-Brightmail-Tracker: AAAAAA==
X-BrightmailFiltered: true
X-IronPort-AV: E=Sophos;i="4.31,225,1215381600"; d="scan'208";a="76393820"
X-Mailing-Address: Post Box 751224 / Petaluma, CA  94975-1224
X-Disclaimer: <http://www.professional.org/procmail/disclaimer.html>
X-Mailman-Version: 2.1.10
List-Post: <mailto:procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE>
List-Subscribe: <http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail>,
    
<mailto:procmail-request(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE?subject=subscribe>
List-Unsubscribe: <http://MailMan.RWTH-Aachen.DE/mailman/options/procmail>,
    
<mailto:procmail-request(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE?subject=unsubscribe>
List-Archive: <http://MailMan.RWTH-Aachen.DE/pipermail/procmail>
List-Help: 
<mailto:procmail-request(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE?subject=help>
List-Id: discussion of the procmail program <procmail.lists.RWTH-Aachen.DE>
X-Bogosity: Unsure, tests=bogofilter, spamicity=0.520000, version=1.0.3


My procmail log:

procmail: Unlocking "/home/swebb/.lockmail"
procmail: [15955] Mon Jul 21 16:03:19 2008
procmail: No match on "^Subject:.SplunkAlert"
procmail: No match on "^From:.nagios"
procmail: No match on "^Subject:.*relay_scanner"
procmail: No match on "^Subject:.*MATCH-IDLE"
procmail: No match on "^Subject:.*Host UP alert"
procmail: No match on "^Subject:.*LOAD is CRITICAL"
procmail: No match on "^Subject:.*LOAD is OK"
procmail: No match on "^Subject:.*PROCMEM is OK"
procmail: No match on "^Subject:.*Disk.* is WARNING"
procmail: No match on "^Subject:.*Disk.* is CRITICAL"
procmail: No match on "^Subject:.*MATCH-IDLE is OK"
procmail: No match on "^Subject:.*MATCH-IDLE is CRITICAL"
procmail: No match on "^Subject:.*PROCMEM is CRITICAL"
procmail: No match on "^Subject:.*Syncing Brad's Images"
procmail: No match on "^To:(_dot_)*memcached(_at_)lists(_dot_)danga(_dot_)com"
procmail: No match on "^To:.*squid-users"
procmail: No match on "^Cc:.*squid-users"
procmail: No match on "^Subject:.*Data Errors"
procmail: No match on "^Subject:.*Data Fixes"
procmail: No match on "^Subject:.*Auto-Pruning"
procmail: No match on "^From:.*bugzilla"
procmail: No match on "(^(((Resent-)?(From|Sender)|X-Envelope-From):|>?From )([^>]*[^((_dot_)%(_at_)a-z0-9])?(Post(ma(st(er)?|n)|office)|(send)?Mail(er)?|daemon|mmdf|n?uucp|ops|r(esponse|oot)|(bbs\.)?smtp(error)?|s(erv(ices?|er)|ystem)|A(dmin(istrator)?|MMGR))(([^).!:a-z0-9][-_a-z0-9]*)?[%@> ][^<)]*(\(.*\).*)?)?$([^>]|$))"
procmail: No match on "^To:(_dot_)*root(_at_)pronto(_dot_)com"
procmail: No match on "^To:(_dot_)*fedora-announce-list(_at_)redhat(_dot_)com"
procmail: No match on "^To:(_dot_)*fedora-legacy-list(_at_)redhat(_dot_)com"
procmail: No match on "^To:.*securityfocus.com"
procmail: No match on "^Cc:.*securityfocus.com"
procmail: No match on "^Subject:.*status"
procmail: Executing "bogofilter,-u,-e,-p,-l"
procmail: No match on "^X-Bogosity: Spam, tests=bogofilter"
procmail: Executing "/usr/bin/spamc"
procmail: [15955] Mon Jul 21 16:03:24 2008
procmail: No match on "^X-Spam-Level: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*"
procmail: No match on "^X-Spam-Status: YES"
procmail: Assigning "LASTFOLDER=/var/spool/mail/swebb"
procmail: Opening "/var/spool/mail/swebb"
procmail: Acquiring kernel-lock
procmail: Notified comsat: "swebb(_at_)544714:/var/spool/mail/swebb"
- From swebb  Mon Jul 21 16:03:19 2008
 Subject: Re: Cyrus and procmail
  Folder: /var/spool/mail/swebb

(The "From swebb" (third line from the bottom) should be
From: PSE-L(_at_)mail(_dot_)professional(_dot_)org, yes)?

NOTE: This procmail log is being processed on my local machine. I fetch mail from the server using fetchmail, which then goes through sendmail, then procmail. When I use procmail on the server, the "From" line in the procmail logs shows "From cyrus(_at_)mail(_dot_)cluster".

If you have a recipe that has:

:0
* ^From:(_dot_)*somaddr(_at_)domain
delivery

It is NOT going to use the Return-Path header instead of From.

Forget the recipes, this is just the log file finding the wrong value for the "From" header. My recipes all work great.

Currently, all emails now get processed as if they're from "cyrus(_at_)mail".

In your MTA, make a copy of the messages so you can see what they look like without your impression of Procmail mangling them.

Is this a known problem?  Should I be contacting the Cyrus people about
this instead?

Probably, since procmail doesn't know cyrus from a hole in the ground, and certainly wouldn't be inserting a header into them using a string which happens to be particular to your IMAP implementation.

Was procmail functioning fine BEFORE your switch to Cyrus? Did you make changes to your procmail config (or even recompile it), or is it just your IMAP daemon that you changed? Are you calling some Cyrus component from within the /etc/procmailrc, or perhaps invoking it from your MTA?

Yea, procmail was working fine before the install of Cyrus, and these procmail issues are popping up on other machines other than the mail server - machines where no other software has been changed, email gets forwarded to those machines and they are also having the same issue.

I can send examples from other machines or the server also if necessary.

- - Steve

- -- Steve Webb - Lead System Administrator for Pronto.com
Email: swebb(_at_)pronto(_dot_)com  (Please send any work requests to: 
rt(_at_)pronto(_dot_)com)
Cell: 303-564-4269, Office: 303-497-9367, YIM: scumola
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)

iD8DBQFIhQysbhtJr2D5JAsRAgrWAKCip0m+mna3IoJZp5tL+aZVkaQ2LwCfX3JC
zA5vf6v7ZwTBzGme1qwT6Yw=
=wkhG
-----END PGP SIGNATURE-----
____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>