[Mimedefang] Milter: rejecting commands ?

Martin Blapp mb at imp.ch
Thu Feb 2 15:42:16 EST 2006

Hi all,

After defineing sub filter_relay() and restarting mimedefang
filtering did not work at all. Instead of processing the mails
sendmail just gets if MX_RELAY_CHECK is set to yes in the startup

Feb  2 21:26:40 mx2 sm-mta[12574]: k12KQenP012574: Milter: connect: 
host=mail22.bluewin.ch, addr=, rejecting commands

Feb  2 21:26:42 mx2 sm-mta[12599]: k12KQft7012599: Milter: connect: 
host=[], addr=, rejecting commands

Feb  2 21:26:42 mx2 sm-mta[12603]: k12KQgMP012603: Milter: connect: 
host=nat0.netburg.pl, addr=, rejecting commands

Feb  2 21:26:44 mx2 sm-mta[12673]: k12KQiwR012673: Milter: connect: 
host=p54BE3907.dip.t-dialin.net, addr=, rejecting commands

Feb  2 21:26:45 mx2 sm-mta[12709]: k12KQjSf012709: Milter: connect: 
host=wirelessdhcp-220-174.ideaone.net, addr=, rejecting commands

Feb  2 21:26:46 mx2 sm-mta[12739]: k12KQk5s012739: Milter: connect: 
host=sproxy.google.com, addr=, rejecting commands

This is mimedefang 2.53. Any ideas ?

Since the check is only for "" true, it should work for all
other adresses.

sub filter_relay {
         my ($ip, $name) = @_;

         if($ip eq "") {
 		return ('REJECT', "Too many spam-mails from $ip, $name is blacklisted.");
         return ('CONTINUE', "ok");


Martin Blapp, <mb at imp.ch> <mbr at FreeBSD.org>
ImproWare AG, UNIXSP & ISP, Zurlindenstrasse 29, 4133 Pratteln, CH
Phone: +41 61 826 93 00 Fax: +41 61 826 93 01
PGP: <finger -l mbr at freebsd.org>
PGP Fingerprint: B434 53FC C87C FE7B 0A18 B84C 8686 EF22 D300 551E

More information about the MIMEDefang mailing list