I have tried to implement this plugin, currently to no avail. I
have it listed in the plugins file immediately before 'check_relay' and it
looks like it is being invoked properly. However, when I connect manually
to localhost:25 and 'mail from: <>', followed by a few 'rcpt to:'
commands, everything is accepted and queued.

        I do wonder about the following routine:

sub mail_handler {
        my ( $self, $transaction, $address )    = @_ ;
        if ( $address->address eq '<>' ) {
                $self->{_nullsender1rcpt_count} = 1 ;
        } else {
                $self->{_nullsender1rcpt_count} = 0 ;
        }
        return DECLINED ;
}

        The posted message 690 originally had both the "then" and the
"else" setting "$self->{_nullsender1rcpt_count}" to 1, but I think the
"else" condition should set it to 0.

        Nevertheless, the logs show the following, so it looks like
"$self->{_nullsender1rcpt_count}" is being set to 1 (that's line 23, per
the Perl error below), but the "rcpt_handler" subroutine isn't actually
incrementing it:

tcpserver: pid  32109 from 127.0.0.1
tcpserver: ok 32109 localhost:127.0.0.1:25 localhost:127.0.0.1::37738
32109 loading plugins from ./plugins
32109 running plugin  check_earlytalker
32109 220 smtp.rope.net - ESMTP
32109 dispatching helo there
32109 running plugin  check_spamhelo
32109 250 nylon.rope.net Helo localhost [127.0.0.1].
32109 dispatching mail from: <>
32109 full from_parameter: from: <>
32109 from email address : [<>]
32109 running plugin  require_resolvable_fromhost
32109 running plugin  nullsender1rcpt
Use of uninitialized value in string eq at ./plugins/nullsender1rcpt line 23, <STDIN> 
line 2.
32109 getting mail from <>
32109 250 <>, sender OK.
32109 dispatching rcpt to: [EMAIL PROTECTED]
32109 running plugin  check_badrcptto
32109 running plugin  nullsender1rcpt
32109 running plugin  check_relay
32109 250 [EMAIL PROTECTED], recipient ok
32109 dispatching rcpt to: [EMAIL PROTECTED]
32109 running plugin  check_badrcptto
32109 running plugin  nullsender1rcpt
32109 running plugin  check_relay
32109 250 [EMAIL PROTECTED], recipient ok
32109 dispatching rcpt to: [EMAIL PROTECTED]
32109 running plugin  check_badrcptto
32109 running plugin  nullsender1rcpt
32109 running plugin  check_relay
32109 250 [EMAIL PROTECTED], recipient ok
32109 dispatching data
32109 354 go ahead
32109 max_size: 0 / size: 56
32109 running plugin  nullsender1rcpt
32109 running plugin  clamav
32109 clamav plugin: Running: /usr/local/bin/clamscan --stdout -i --mbox 
--max-recursion=50 --disable-summary /tmp/YGB1CXYF9w 2>&1
32109 clamav plugin: clamscan results:
32109 running plugin  queue::qmail_2dqueue
32109 250 Queued!
32109 dispatching quit
32109 221 nylon.rope.net closing connection.
tcpserver: end 32109 status 0

        Can anyone shed some light on what is happening, and what may need
to change?

        Thanks.

-- 
Roger Walker
"His Pain - Our Gain"

Reply via email to