Aaron Stone wrote:

Ilja Booij <[EMAIL PROTECTED]> said:

Thomas Mueller wrote:

I get about 20 mails a week like this one:

from: [EMAIL PROTECTED]
subject: dbmail IMAP server info: this message could not be parsed

The message body is the mail that could not be parsed (normally spam
with strange mime parts).

Is it possible to set another sender (the admin of the mailserver) and
some text at the beginning that explains to an average user what
happend?


We've had a few of these messages as well. It just looked at it, and it turns out to be hardcoded in
rfcmsg.c ... :(

Not good.

Is there something *really simple* that we can put into the config file
and connect to delivery, to enable copying the message to the postmaster?

Otherwise we'll have to put this off until 2.1 when we'll have the rest of
the delivery framework finished, in particular the sorting support, and
make sure that it can handle additional destination added from within
DBMail -- basically the failed MIME parse would add postmaster to the
delivery list.

By then we'll have a more featureful and tolerant MIME parser anyways, but
it's still a good idea in general to be able to copy any major errors
during message delivery over to the postmaster.
I've added a small patch in the bugtracker that will set the postmaster address (as taken from dbmail.conf) as
the From: address. I'll also attach it here.

This does not doing anything else though..

Can you people test this? I haven't (yet) succeeded in getting a message from our database and reproducing the problem.

Ilja

Ilja

--
Ilja Booij
IC&S B.V.

Stadhouderslaan 57
3583 JD  Utrecht
www.ic-s.nl

T algemeen: 030 6355730
T direct: 030 6355739
F: 030 6355731
E: [EMAIL PROTECTED]

--- rfcmsg.c    Fri Aug 20 15:24:06 2004
+++ rfcmsg.c.new        Fri Aug 20 14:53:39 2004
@@ -747,6 +747,7 @@
        int result;
        struct mime_record mr;
        struct element *el = NULL;
+       field_t postmaster;
 
        memset(msg, 0, sizeof(*msg));
 
@@ -758,7 +759,8 @@
                return -3;
 
        strcpy(mr.field, "from");
-       strcpy(mr.value, "[EMAIL PROTECTED]");
+       GetConfigValue("POSTMASTER", "SMTP", postmaster);
+       strncpy(mr.value, postmaster, MIME_VALUE_MAX - 1);
        el = list_nodeadd(&msg->rfcheader, &mr, sizeof(mr));
        if (!el)
                return -3;

Reply via email to