should dccproc log all messages with -cCMN,10,many ?

Brad Volz bradv@affectation.org
Fri Dec 27 09:03:28 UTC 2002


Hello,

I seem to be having trouble getting 'dccproc -c' to behave in the
way I understand the documentation.  Perhaps I misunderstood the
man page, or maybe I am just doing something wrong.  It is my
interpretation of the man page that using dccproc with "-c CMN,10,many"
should produce the following results.

    - if the counts of Body, Fuz1, or Fuz2 are >= 10, then
      log the message
    - if the counts of Body, Fuz1, or Fuz2 are "many", then
      consider the message bulk which -
          a. adds the bulk keyword to the X-DCC header
          b. causes dccproc to exit with EX_NOUSER

The part that I am having trouble with is controlling the logging.
Currently, dccproc is logging all messages, regardless of their
checksum counts.  Everything else works just fine.

This is the dccproc version 1.1.15.

I am using dccproc as a Postfix content_filter.  If it is useful,
here is the part of the script that pushes the message through dccproc.

- ---
# Start processing.
cd $INSPECT_DIR || { echo $INSPECT_DIR does not exist; exit $EX_TEMPFAIL; }

cat >in.$$ || { echo Cannot save mail to file; exit $EX_TEMPFAIL; }

DCC_BASE=/var/chroot/dccd
DCC_WHITECLNT_USER=` echo $4 | sed -e 's/\@.*//' `
DCC_DCCPROC_LOG=10
DCC_DCCPROC_REJ=many
DCC_DCCPROC_C_ARG="CMN,$DCC_DCCPROC_LOG,$DCC_DCCPROC_REJ"

# check to see if a per-user whitelist exists, otherwise use
# the system whitelist
if [ -f $DCC_BASE/userdirs/local/$DCC_WHITECLNT_USER/whiteclnt ]; then
    cat in.$$ | /usr/local/bin/dccproc -ER \
    -w $DCC_BASE/userdirs/local/$DCC_WHITECLNT_USER/whiteclnt \
    -c "$DCC_DCCPROC_C_ARG" \
    -l $DCC_BASE/userdirs/local/$DCC_WHITECLNT_USER/log > out.$$
else
    cat in.$$ | /usr/local/bin/dccproc -ERw whiteclnt \
    -h $DCC_BASE > out.$$
fi
- ---

So, I guess my question is - Do I correctly understand dccproc's -c option
( which implies that my content_filter script is broken somehow ), or is
dccproc intended to log all messages?  My goal is to only log
messages that have some degree of bulk (~10 or so)  to them.

Thanks,

Brad



More information about the DCC mailing list

Contact vjs@rhyolite.com by mail or use the form.