diff xml/sample.conf @ 80:d554e41f2886

start coding on new config syntax
author carl
date Sat, 16 Jul 2005 20:25:35 -0700
parents 81f1e400e8ab
children 7e4a90e5f213
line wrap: on
line diff
--- a/xml/sample.conf	Sat Jul 16 20:12:20 2005 -0700
+++ b/xml/sample.conf	Sat Jul 16 20:25:35 2005 -0700
@@ -1,7 +1,10 @@
 # $Id$
 #
 
-# partial bnf description of this configuration language
+# Partial bnf description of this configuration language. Any sequence of
+# three tokens ("include" FILENAME ";") are replaced by the content of the
+# specified file.
+#
 #
 # CONFIG            = {CONTEXT ";"}+
 # CONTEXT           = "context" NAME "{" {STATEMENT}+ "}"
@@ -27,7 +30,7 @@
 # TO-ADDR           = ADDRESS [";"]
 # DCC-TO            = "dcc_to" ("ok" | "many") "{" DCCINCLUDEFILE "}" ";"
 
-# ENV_FROM          = "env_from" DEFAULT "{" {(FROM-ADDR | DCC-FROM)}+ "}"
+# ENV_FROM          = "env_from" [DEFAULT] "{" {(FROM-ADDR | DCC-FROM)}+ "}"
 # FROM-ADDR         = ADDRESS VALUE [";"]
 # DCC-FROM          = "dcc_from" "{" DCCINCLUDEFILE "}" ";"
 # DEFAULT           = ("white" | "black" | "unknown" | "inherit" | "")
@@ -65,7 +68,7 @@
     context whitelist {
         content off {};
         env_to {
-            # dcc_to ok { include "/var/dcc/whitecommon"; };
+            # dcc_to ok { include "/var/dcc/whitecommon"; };    # copy the dcc OK values (env_to) into this context
         };
         env_from white {};      # white forces all unmatched from addresses (everyone in this case) to be whitelisted
                                 # so all mail TO these env_to addresses is accepted
@@ -91,7 +94,7 @@
 
     context blacklist {
         env_to {
-            dcc_to many { include "/var/dcc/whitecommon"; };
+            dcc_to many { include "/var/dcc/whitecommon"; };    # copy the dcc MANY values (env_to) into this context
             old-employee@mydomain.com;
         };
         env_from black {};      # black forces all unmatched from addresses (everyone in this case) to be blacklisted
@@ -128,7 +131,7 @@
             };
         };
 
-        env_from inherit {
+        env_from {  # default value of the default is inherit
             yahoo.com           black;      # no mail from yahoo
             first@yahoo.com     unknown;    # except this one
         };
@@ -144,7 +147,7 @@
     };
 
     env_from unknown {
-        dcc_from { include "/var/dcc/whitecommon"; };   # use the dcc whitecommon list ok/many values to white/black list envelope from values here
+        dcc_from { include "/var/dcc/whitecommon"; };   # copy the dcc OK/MANY values (env_from, substitute mail_host) into this context
         abuse@              abuse;      # replies to abuse reports use the abuse context
         yahoo.com           black;      # don't take mail from yahoo
         spammer@example.com black;