From sendmail Tue May 21 08:45:01 2002 From: Eric Devolder Date: Tue, 21 May 2002 08:45:01 +0000 To: sendmail Subject: extended FEATURE for dnsbl : allowing to use mirror DNS sites X-MARC-Message: https://marc.info/?l=sendmail&m=102244752115682 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--nextPart1504791.XfaGNgDLYL" --nextPart1504791.XfaGNgDLYL Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 8Bit Hello there. The well-known dnsbl feature is quite interesting, but a problem arise when the NS server is a mirror. Example: let's say that BL1.NET is the primary NS, and B2.ORG one of its mirror. by using the feature with the mirror site, it will not work as the basic feature will append the mirror domain name to the query, not the original server one. Here follows a revised dnsbl() feature (which I named dnsbl_mirror), for testing. However, the best would be to directly add the features to dnsbl itself. Any comments are appreciated. edevolder@anti-spam-remove-me.eft.be (don't forget to remove the header in the domain address ) --nextPart1504791.XfaGNgDLYL Content-Type: text/plain; name="dnsbl_mirror.m4" Content-Transfer-Encoding: 8Bit Content-Disposition: attachment; filename="dnsbl_mirror.m4" divert(-1) # # Copyright (c) 1998, 1999 Sendmail, Inc. and its suppliers. # All rights reserved. # # By using this file, you agree to the terms and conditions set # forth in the LICENSE file which can be found at the top level of # the sendmail distribution. # # divert(0) ifdef(`_DNSBL_R_',`dnl',`dnl VERSIONID(`$Id: dnsbl_mirror.m4,v 8.18.16.1 2000/11/22 01:13:21 ca Exp $')') divert(-1) define(`_DNSBL_SRV_', `ifelse(len(X`'_ARG_),`1',`blackholes.mail-abuse.org',_ARG_)')dnl define(`_DNSBL_SFX_', `ifelse(len(X`'_ARG2_),`1',`_DNSBL_SRV_',_ARG2_)')dnl define(`_DNSBL_MSG_', `ifelse(len(X`'_ARG3_),`1',`"550 Mail from " $`'&{client_addr} " refused by blackhole site '_DNSBL_SFX_`"',`_ARG3_')')dnl divert(8) # DNS based IP address spam list _DNSBL_SRV_ R$* $: $&{client_addr} R::ffff:$-.$-.$-.$- $: $(host $4.$3.$2.$1._DNSBL_SFX_. $: OK $) R$-.$-.$-.$- $: $(host $4.$3.$2.$1._DNSBL_SFX_. $: OK $) ROK $: OKSOFAR R$+ $#error $@ 5.7.1 $: _DNSBL_MSG_ divert(-1) --nextPart1504791.XfaGNgDLYL--