comparison xml/dnsbl.in @ 233:5c3e9bf45bb5 stable-6-0-23

Add whitelisting by regex expression filtering. Add queueid to whitelist extension log message.
author Carl Byington <carl@five-ten-sg.com>
date Mon, 25 May 2009 11:14:32 -0700
parents 784030ac71f1
children 8b0f16abee53
comparison
equal deleted inserted replaced
232:768ce0f23149 233:5c3e9bf45bb5
17 17
18 </partintro> 18 </partintro>
19 19
20 <refentry id="@PACKAGE@.1"> 20 <refentry id="@PACKAGE@.1">
21 <refentryinfo> 21 <refentryinfo>
22 <date>2008-06-08</date> 22 <date>2009-05-25</date>
23 </refentryinfo> 23 </refentryinfo>
24 24
25 <refmeta> 25 <refmeta>
26 <refentrytitle>@PACKAGE@</refentrytitle> 26 <refentrytitle>@PACKAGE@</refentrytitle>
27 <manvolnum>1</manvolnum> 27 <manvolnum>1</manvolnum>
362 <listitem><para> 362 <listitem><para>
363 If the answer is inherit, we repeat the envelope from search in the 363 If the answer is inherit, we repeat the envelope from search in the
364 parent context. 364 parent context.
365 </para></listitem> 365 </para></listitem>
366 <listitem><para> 366 <listitem><para>
367 If the mail has not been accepted or rejected yet, and the filtering
368 context (or any ancestor context) specifies a non-empty whitelist regular
369 expression, then we check the envelope from value against that regex.
370 The mail is accepted if the envelope from value matches the specified regular
371 expression.
372 </para></listitem>
373 <listitem><para>
367 If the mail has not been accepted or rejected yet, the dns lists 374 If the mail has not been accepted or rejected yet, the dns lists
368 specified in the filtering context are checked and the mail is rejected 375 specified in the filtering context are checked and the mail is rejected
369 if any list has an A record for the standard dns based lookup scheme 376 if any list has an A record for the standard dns based lookup scheme
370 (reversed octets of the client followed by the dns suffix). 377 (reversed octets of the client followed by the dns suffix).
371 </para></listitem> 378 </para></listitem>
584 </refentry> 591 </refentry>
585 592
586 593
587 <refentry id="@PACKAGE@.conf.5"> 594 <refentry id="@PACKAGE@.conf.5">
588 <refentryinfo> 595 <refentryinfo>
589 <date>2008-06-08</date> 596 <date>2009-05-25</date>
590 </refentryinfo> 597 </refentryinfo>
591 598
592 <refmeta> 599 <refmeta>
593 <refentrytitle>@PACKAGE@.conf</refentrytitle> 600 <refentrytitle>@PACKAGE@.conf</refentrytitle>
594 <manvolnum>5</manvolnum> 601 <manvolnum>5</manvolnum>
617 </para> 624 </para>
618 625
619 <literallayout class="monospaced"><![CDATA[ 626 <literallayout class="monospaced"><![CDATA[
620 CONFIG = {CONTEXT ";"}+ 627 CONFIG = {CONTEXT ";"}+
621 CONTEXT = "context" NAME "{" {STATEMENT}+ "}" 628 CONTEXT = "context" NAME "{" {STATEMENT}+ "}"
622 STATEMENT = (DNSBL | DNSBLLIST | CONTENT | ENV-TO | VERIFY | GENERIC 629 STATEMENT = (DNSBL | DNSBLLIST | CONTENT | ENV-TO | VERIFY | GENERIC
623 | AUTOWHITE | CONTEXT | ENV-FROM | RATE-LIMIT) ";" 630 | W_REGEX | AUTOWHITE | CONTEXT | ENV-FROM | RATE-LIMIT) ";"
624 631
625 DNSBL = "dnsbl" NAME DNSPREFIX ERROR-MSG1 632 DNSBL = "dnsbl" NAME DNSPREFIX ERROR-MSG1
626 633
627 DNSBLLIST = "dnsbl_list" {NAME}+ 634 DNSBLLIST = "dnsbl_list" {NAME}+
628 635
657 TO-ADDR = ADDRESS [";"] 664 TO-ADDR = ADDRESS [";"]
658 DCC-TO = "dcc_to" ("ok" | "many") "{" DCCINCLUDEFILE "}" ";" 665 DCC-TO = "dcc_to" ("ok" | "many") "{" DCCINCLUDEFILE "}" ";"
659 666
660 VERIFY = "verify" HOSTNAME ";" 667 VERIFY = "verify" HOSTNAME ";"
661 GENERIC = "generic" REGULAREXPRESSION ERROR-MSG4 ";" 668 GENERIC = "generic" REGULAREXPRESSION ERROR-MSG4 ";"
669 W-REGEX = "white_regex" REGULAREXPRESSION ";"
662 ERROR-MSG4 = string containing exactly one %s replacement token 670 ERROR-MSG4 = string containing exactly one %s replacement token
663 which is replaced with the client name 671 which is replaced with the client name
664 AUTOWHITE = "autowhite" DAYS FILENAME ";" 672 AUTOWHITE = "autowhite" DAYS FILENAME ";"
665 673
666 ENV_FROM = "env_from" [DEFAULT] "{" {(FROM-ADDR | DCC-FROM)}+ "}" 674 ENV_FROM = "env_from" [DEFAULT] "{" {(FROM-ADDR | DCC-FROM)}+ "}"
739 }; 747 };
740 748
741 generic "^dsl.static.*ttnet.net.tr$|(^|[x.-])(ppp|h|host)?([0-9]{1,3}[x.-](Red-|dynamic[x.-])?){4}" 749 generic "^dsl.static.*ttnet.net.tr$|(^|[x.-])(ppp|h|host)?([0-9]{1,3}[x.-](Red-|dynamic[x.-])?){4}"
742 "your mail server %s seems to have a generic name"; 750 "your mail server %s seems to have a generic name";
743 751
752 white_regex ".*=example.com=user@yourhostingaccount.com";
753
744 env_to { 754 env_to {
745 # !! replace this with your domain names 755 # !! replace this with your domain names
746 # child contexts are not allowed to specify recipient addresses outside these domains 756 # child contexts are not allowed to specify recipient addresses outside these domains
747 # if this is a backup-mx, you need to include here domains for which you relay to the primary mx 757 # if this is a backup-mx, you need to include here domains for which you relay to the primary mx
748 include "/etc/mail/local-host-names"; 758 include "/etc/mail/local-host-names";