[Dovecot] BUG in RC10 deliver using mbox format

Steven F Siirila sfs at tc.umn.edu
Sat Oct 28 03:34:43 UTC 2006


After recently adding the -f parameter to the call to the deliver command
which is called by Postfix, I found that e-mail with a null return path
(MAIL FROM:<>) was causing Dovecot deliver to SEGFAULT.  I verified this
by making this patch to deliver.c (notice I fixed a typo here, too):

*** deliver.c.orig      Fri Oct 13 07:32:28 2006
--- deliver.c   Fri Oct 27 21:26:08 2006
***************
*** 446,454 ****
                        i++;
                        if (i == argc) {
                                i_fatal_status(EX_USAGE,
!                                              "Missing envleope argument");
                        }
!                       envelope_sender = argv[i];
                } else {
                        print_help();
                        i_fatal_status(EX_USAGE,
--- 446,455 ----
                        i++;
                        if (i == argc) {
                                i_fatal_status(EX_USAGE,
!                                              "Missing envelope argument");
                        }
!                       if (*argv[i])
!                               envelope_sender = argv[i];
                } else {
                        print_help();
                        i_fatal_status(EX_USAGE,

While this fixed my SEGFAULT, it still leaves the "From_" line with the
default "dovecot.deliver" as the return path, something I don't want.
It should be "MAILER-DAEMON" or some-such just like all the other LDAs
in the case of a NULL return path.  Perhaps there needs to be a new
parameter so one can specify what a NULL return path should be converted to
when it is encountered...

Also, note that the "Usage" message in deliver.c does not include the
relatively new -f option either, so that should have been part of my
above patch as well.

-- 

Steven F. Siirila			Office: Lind Hall, Room 130B
Internet Services			E-mail: sfs at umn.edu
Office of Information Technology	Voice: (612) 626-0244
University of Minnesota			Fax: (612) 626-7593


More information about the dovecot mailing list