You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Joey <Jo...@Web56.Net> on 2007/11/05 21:33:56 UTC

Mail getting stripped and delivered blank

Hello All,

 

I have a situation where a user gets a blank subject, and blank body, there
is really NO information in the email so it's not possible to add too much
info here.

 

I believe the following is the transaction between postfix and then spamd I
believe re-injecting the message:

 

Nov  5 14:28:24 pluto postfix/smtpd[7161]: NOQUEUE: filter: RCPT from
sender-server.com[12.185.14.14]: <cl...@recipientemail.com>: Recipient
address triggers FILTER filter:dummy; from=<se...@sender.com>
to=<cl...@recipientemail.com> proto=ESMTP helo=<sender-server.com>

Nov  5 14:28:29 pluto postfix/qmgr[5904]: 2A0202340FD:
from=<se...@sender.com>, size=15085, nrcpt=1 (queue active)

Nov  5 14:28:32 pluto postfix/pickup[8557]: F233E234106: uid=10816
from=<se...@sender.com>

Nov  5 14:28:33 pluto postfix/qmgr[5904]: F233E234106:
from=<se...@sender.com>, size=300, nrcpt=1 (queue active)

 

>From what I see here I see the size of the original email is larger then the
final email.

 

Has there become a way to maintain the message ID throughout the process to
be certain of every step?

 

I am thinking the SPAMD was NOT loaded since we had just restarted the
server to update kernel's.

Would this type of thing happen if spamd isn't loaded?

Shouldn't spamd load on it's own non-damonized. ( if that's a word )

 

 

My master.cf file has this filter entry:

filter    unix  -   n   n   -   -   pipe

    flags=Rq user=filter argv=/var/spool/filter/filter.sh -f ${sender} --
${recipient}

 

 

I have this in my filter.sh:

SENDMAIL="/usr/sbin/sendmail -i"

#SPAMASSASSIN=/usr/bin/spamassassin

SPAMASSASSIN=/usr/bin/spamc

 

# Exit codes from <sysexits.h>

EX_TEMPFAIL=75

EX_UNAVAILABLE=69

 

cat | $SPAMASSASSIN -x | $SENDMAIL "$@" || \

   { echo Message content rejected; exit $EX_UNAVAILABLE; }

 

exit 0

 

 

Any help is appreciated!

 

Joey

 



Re: Mail getting stripped and delivered blank

Posted by Noel Jones <no...@gmail.com>.
On 11/5/07, Joey <Jo...@web56.net> wrote:
> I have a situation where a user gets a blank subject, and blank body, there
> is really NO information in the email so it's not possible to add too much
> info here.
>
> I believe the following is the transaction between postfix and then spamd I
> believe re-injecting the message:
>
> Nov  5 14:28:24 pluto postfix/smtpd[7161]: NOQUEUE: filter: RCPT from
> sender-server.com[12.185.14.14]: <cl...@recipientemail.com>: Recipient
> address triggers FILTER filter:dummy; from=<se...@sender.com>
> to=<cl...@recipientemail.com> proto=ESMTP helo=<sender-server.com>
>
> Nov  5 14:28:29 pluto postfix/qmgr[5904]: 2A0202340FD:
> from=<se...@sender.com>, size=15085, nrcpt=1 (queue active)
>

OK, message size ~15k.

> Nov  5 14:28:32 pluto postfix/pickup[8557]: F233E234106: uid=10816
> from=<se...@sender.com>
>
> Nov  5 14:28:33 pluto postfix/qmgr[5904]: F233E234106:
> from=<se...@sender.com>, size=300, nrcpt=1 (queue active)

Message size 300 bytes.  Either it's a different message or something
ate the content.

> Has there become a way to maintain the message ID throughout the process to
> be certain of every step?

The Message-ID (a message header) will stay the same, and is logged by
the postfix cleanup process - but if something eats the message
content, the Message-ID will get eaten along with the rest.
The postfix QUEUEID (shown in your logging samples above) will always
be different when using a content_filter, because it's a different
queue file.

Don't confuse the QUEUEID with the Message-ID.

> I am thinking the SPAMD was NOT loaded since we had just restarted the
> server to update kernel's.
>
> Would this type of thing happen if spamd isn't loaded?

Possibly yes, if you use the -x flag to spamc.

> Shouldn't spamd load on it's own non-damonized. ( if that's a word )

Spamc will pass the mail through unchecked if spamd isn't running,
unless you use the -x flag.  See the spamc man page.

> My master.cf file has this filter entry:
>
> filter    unix  -   n   n   -   -   pipe
>
>     flags=Rq user=filter argv=/var/spool/filter/filter.sh -f ${sender} --
> ${recipient}

OK.


> I have this in my filter.sh:
>
> SENDMAIL="/usr/sbin/sendmail -i"
>
> #SPAMASSASSIN=/usr/bin/spamassassin
>
> SPAMASSASSIN=/usr/bin/spamc
>
>
>
> # Exit codes from <sysexits.h>
>
> EX_TEMPFAIL=75
>
> EX_UNAVAILABLE=69
>
>
>
> cat | $SPAMASSASSIN -x | $SENDMAIL "$@" || \
>
>    { echo Message content rejected; exit $EX_UNAVAILABLE; }
>

Looks as if you're passing spamc the -x flag, telling spamc to fail if
spamd isn't available, and then not checking for the exit status of
$SPAMASSASSIN.


>
> exit 0
>
>
>
>
>
> Any help is appreciated!
>
>
>
> Joey


-- 
Noel Jones