Update of /cvsroot/tmda/tmda/htdocs
In directory sc8-pr-cvs1:/tmp/cvs-serv21670

Modified Files:
        config-vars.ht config-vars.html filter-sources.ht 
        filter-sources.html 
Log Message:
Added variables and filter specifications for MySQL sources.


Index: config-vars.ht
===================================================================
RCS file: /cvsroot/tmda/tmda/htdocs/config-vars.ht,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- config-vars.ht      12 Mar 2003 23:20:42 -0000      1.20
+++ config-vars.ht      23 Mar 2003 23:23:53 -0000      1.21
@@ -145,77 +145,87 @@
 <td><a href="#MESSAGE_TAG_HEADER_STYLE">MESSAGE_TAG_HEADER_STYLE</a></td>
 </tr>
 <tr>
+<td><a href="#MYSQL_DATABASE">MYSQL_DATABASE</a></td>
+<td><a href="#MYSQL_ENABLED">MYSQL_ENABLED</a></td>
+</tr>
+<tr>
+<td><a href="#MYSQL_HOST">MYSQL_HOST</a></td>
+<td><a href="#MYSQL_PASSWORD">MYSQL_PASSWORD</a></td>
+</tr>
+<tr>
+<td><a href="#MYSQL_USER">MYSQL_USER</a></td>
 <td><a href="#OUTGOINGMAIL">OUTGOINGMAIL</a></td>
-<td><a href="#PENDING_BLACKLIST_APPEND">PENDING_BLACKLIST_APPEND</a></td>
 </tr>
 <tr>
+<td><a href="#PENDING_BLACKLIST_APPEND">PENDING_BLACKLIST_APPEND</a></td>
 <td><a href="#PENDING_CACHE">PENDING_CACHE</a></td>
-<td><a href="#PENDING_CACHE_LEN">PENDING_CACHE_LEN</a></td>
 </tr>
 <tr>
+<td><a href="#PENDING_CACHE_LEN">PENDING_CACHE_LEN</a></td>
 <td><a href="#PENDING_DELETE_APPEND">PENDING_DELETE_APPEND</a></td>
-<td><a href="#PENDING_RELEASE_APPEND">PENDING_RELEASE_APPEND</a></td>
 </tr>
 <tr>
+<td><a href="#PENDING_RELEASE_APPEND">PENDING_RELEASE_APPEND</a></td>
 <td><a href="#PENDING_WHITELIST_APPEND">PENDING_WHITELIST_APPEND</a></td>
-<td><a href="#PRIMARY_ADDRESS_MATCH">PRIMARY_ADDRESS_MATCH</a></td>
 </tr>
 <tr>
+<td><a href="#PRIMARY_ADDRESS_MATCH">PRIMARY_ADDRESS_MATCH</a></td>
 <td><a href="#PURGED_HEADERS">PURGED_HEADERS</a></td>
-<td><a href="#RECIPIENT_DELIMITER">RECIPIENT_DELIMITER</a></td>
 </tr>
 <tr>
+<td><a href="#RECIPIENT_DELIMITER">RECIPIENT_DELIMITER</a></td>
 <td><a href="#RECIPIENT_HEADER">RECIPIENT_HEADER</a></td>
-<td><a href="#RESPONSE_DIR">RESPONSE_DIR</a></td>
 </tr>
 <tr>
+<td><a href="#RESPONSE_DIR">RESPONSE_DIR</a></td>
 <td><a href="#SENDER_TEMPLATE_VARS">SENDER_TEMPLATE_VARS</a></td>
-<td><a href="#SENDMAIL_PROGRAM">SENDMAIL_PROGRAM</a></td>
 </tr>
 <tr>
+<td><a href="#SENDMAIL_PROGRAM">SENDMAIL_PROGRAM</a></td>
 <td><a href="#SMTPAUTH_PASSWORD">SMTPAUTH_PASSWORD</a></td>
-<td><a href="#SMTPAUTH_USERNAME">SMTPAUTH_USERNAME</a></td>
 </tr>
 <tr>
+<td><a href="#SMTPAUTH_USERNAME">SMTPAUTH_USERNAME</a></td>
 <td><a href="#SMTPHOST">SMTPHOST</a></td>
-<td><a href="#SMTPSSL">SMTPSSL</a></td>
 </tr>
 <tr>
+<td><a href="#SMTPSSL">SMTPSSL</a></td>
 <td><a href="#SMTPSSL_CERTFILE">SMTPSSL_CERTFILE</a></td>
-<td><a href="#SMTPSSL_KEYFILE">SMTPSSL_KEYFILE</a></td>
 </tr>
 <tr>
+<td><a href="#SMTPSSL_KEYFILE">SMTPSSL_KEYFILE</a></td>
 <td><a 
href="#SMTP_MAX_SESSIONS_PER_CONNECTION">SMTP_MAX_SESSIONS_PER_CONNECTION</a></td>
-<td><a href="#SUMMARY_HEADERS">SUMMARY_HEADERS</a></td>
 </tr>
 <tr>
+<td><a href="#SUMMARY_HEADERS">SUMMARY_HEADERS</a></td>
 <td><a href="#TAGS_CONFIRM">TAGS_CONFIRM</a></td>
-<td><a href="#TAGS_DATED">TAGS_DATED</a></td>
 </tr>
 <tr>
+<td><a href="#TAGS_DATED">TAGS_DATED</a></td>
 <td><a href="#TAGS_KEYWORD">TAGS_KEYWORD</a></td>
-<td><a href="#TAGS_SENDER">TAGS_SENDER</a></td>
 </tr>
 <tr>
+<td><a href="#TAGS_SENDER">TAGS_SENDER</a></td>
 <td><a href="#TEMPLATE_DIR">TEMPLATE_DIR</a></td>
-<td><a href="#TEMPLATE_DIR_MATCH_SENDER">TEMPLATE_DIR_MATCH_SENDER</a></td>
 </tr>
 <tr>
+<td><a href="#TEMPLATE_DIR_MATCH_SENDER">TEMPLATE_DIR_MATCH_SENDER</a></td>
 <td><a href="#TEMPLATE_EMAIL_HEADERS">TEMPLATE_EMAIL_HEADERS</a></td>
-<td><a href="#TEMPLATE_ENCODED_HEADERS">TEMPLATE_ENCODED_HEADERS</a></td>
 </tr>
 <tr>
+<td><a href="#TEMPLATE_ENCODED_HEADERS">TEMPLATE_ENCODED_HEADERS</a></td>
 <td><a href="#TERSE_SUMMARY_HEADERS">TERSE_SUMMARY_HEADERS</a></td>
-<td><a href="#TIMEOUT">TIMEOUT</a></td>
 </tr>
 <tr>
+<td><a href="#TIMEOUT">TIMEOUT</a></td>
 <td><a href="#USERNAME">USERNAME</a></td>
-<td><a href="#USEVIRTUALDOMAINS">USEVIRTUALDOMAINS</a></td>
 </tr>
 <tr>
+<td><a href="#USEVIRTUALDOMAINS">USEVIRTUALDOMAINS</a></td>
 <td><a href="#VIRTUALDOMAINS">VIRTUALDOMAINS</a></td>
-<td><a href="#X_TMDA_IN_SUBJECT">X_TMDA_IN_SUBJECT</a></td>
 </tr>
+<tr>
+<td><a href="#X_TMDA_IN_SUBJECT">X_TMDA_IN_SUBJECT</a></td>
 </table>
 
 <dl>
@@ -1050,6 +1060,63 @@
 <br><br>
 The valid values and default value is identical to that of
 MESSAGE_FROM_STYLE.
+<dt><hr>
+<a name="MYSQL_DATABASE"><h4>MYSQL_DATABASE</h4></a>
+<dd>
+MySQL database containing any lists used in filter.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_DATABASE = "JimsTMDA"</code>
+<br><br>
+Default is "TMDA".
+<dt><hr>
+<a name="MYSQL_ENABLED"><h4>MYSQL_ENABLED</h4></a>
+<dd>
+All defaults beginning with "MYSQL_" configure the use of a MySQL
+database in the filtering process.  To use a MySQL database, you
+must have the _mysql library loaded.  See:
+<br>
+http://sourceforge.net/projects/mysql-python/
+<br><br>
+MYSQL_ENABLED must be set to 1 if you wish to use a MySQL database
+in your filters.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_ENABLED = 1</code>
+<br><br>
+Default is 0 (disabled)
+<dt><hr>
+<a name="MYSQL_HOST"><h4>MYSQL_HOST</h4></a>
+<dd>
+MySQL host to connect to.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_HOST = "db.my.server"</code>
+<br><br>
+Default is "localhost".
+<dt><hr>
+<a name="MYSQL_PASSWORD"><h4>MYSQL_PASSWORD</h4></a>
+<dd>
+MySQL password to use when connecting to database.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_USER = "[EMAIL PROTECTED]"</code>
+<br><br>
+Default is "".
+<dt><hr>
+<a name="MYSQL_USER"><h4>MYSQL_USER</h4></a>
+<dd>
+MySQL user to use when connecting to database.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_USER = "Jim"</code>
+<br><br>
+Default is "TMDA".
 <dt><hr>
 <a name="OUTGOINGMAIL"><h4>OUTGOINGMAIL</h4></a>
 <dd>

Index: config-vars.html
===================================================================
RCS file: /cvsroot/tmda/tmda/htdocs/config-vars.html,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- config-vars.html    17 Mar 2003 21:21:35 -0000      1.35
+++ config-vars.html    23 Mar 2003 23:23:53 -0000      1.36
@@ -1,185 +1,190 @@
-<HTML>
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
 <!-- THIS PAGE IS AUTOMATICALLY GENERATED.  DO NOT EDIT. -->
-<!-- Mon Mar 17 14:19:04 2003 -->
-<!-- USING HT2HTML 1.2 -->
-<!-- SEE http://barry.wooz.org/software/ht2html -->
+<!-- Sun Mar 23 17:22:56 2003 -->
+<!-- USING HT2HTML 2.0 -->
+<!-- SEE http://ht2html.sf.net -->
 <!-- User-specified headers:
 Title: TMDA Configuration Variables
 
 -->
 
-<HEAD>
-<TITLE>TMDA Configuration Variables</TITLE>
-
-</HEAD>
-<BODY BGCOLOR="#ffffff" TEXT="#000000"
-      TOPMARGIN="0" LEFTMARGIN="0" MARGINWIDTH="0" MARGINHEIGHT="0"
-      LINK="#0000bb"  VLINK="#551a8b"
-      ALINK="#ff0000">
+<head>
+<title>TMDA Configuration Variables</title>
+<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
+<meta name="generator" content="HT2HTML/2.0">
+<style type="text/css">
+body { margin: 0px; }
+</style>
+</head>
+<body bgcolor="#ffffff" text="#000000"
+      marginwidth="0" marginheight="0"
+      link="#0000bb"  vlink="#551a8b"
+      alink="#ff0000">
 <!-- start of page table -->
-<TABLE WIDTH="100%" BORDER=0 CELLSPACING=0 CELLPADDING=0>
+<table width="100%" border="0" cellspacing="0" cellpadding="0">
 <!-- start of banner row -->
-<TR>
+<tr>
 <!-- start of corner cells -->
-<TD WIDTH=150 VALIGN=CENTER BGCOLOR="#afeeee">
+<td width="150" valign="middle" bgcolor="#afeeee" class="corner">
 <center><font size="+2"
-        >&gt;&gt;&gt;&nbsp;TMDA&nbsp</font></center> </TD>
-<TD WIDTH=15 BGCOLOR="#cccccc">&nbsp;&nbsp;</TD><!--spacer-->
+        >&gt;&gt;&gt;&nbsp;TMDA&nbsp</font></center> </td>
+<td width="15" bgcolor="#cccccc">&nbsp;&nbsp;</td><!--spacer-->
 <!-- end of corner cells -->
 <!-- start of banner -->
-<TD WIDTH="90%" BGCOLOR="#cccccc">
+<td width="90%" bgcolor="#cccccc" class="banner">
 <!-- start of site links table -->
-<TABLE WIDTH="100%" BORDER=0
+<table width="100%" border="0"
 CELLSPACING=0 CELLPADDING=0
-       COLS=4 ROWS=1 BGCOLOR="#ffffff">
-<TR>
-    <TD BGCOLOR="#cccccc">
+       bgcolor="#ffffff">
+<tr>
+    <td bgcolor="#cccccc">
 <a href="./index.html">TMDA Homepage</a><br>[    <a 
href="http://www.au.tmda.net/";>AU</a> |    <a href="http://www.us.tmda.net/";>US</a>    
 mirror ]
-    </TD>
-    <TD BGCOLOR="#cccccc">
+    </td>
+    <td bgcolor="#cccccc">
 <a href="http://sourceforge.net/projects/tmda";>TMDA @ SourceForge</a>
-    </TD>
-    <TD BGCOLOR="#cccccc">
-&nbsp;&nbsp;</TD>
-    <TD BGCOLOR="#cccccc">
-&nbsp;&nbsp;</TD>
-</TR>
-</TABLE><!-- end of site links table -->
+    </td>
+    <td bgcolor="#cccccc">
+&nbsp;&nbsp;</td>
+    <td bgcolor="#cccccc">
+&nbsp;&nbsp;</td>
+</tr>
+</table><!-- end of site links table -->
 
-</TD><!-- end of banner -->
-</TR><!-- end of banner row -->
-<TR><!-- start of sidebar/body row -->
+</td><!-- end of banner -->
+</tr><!-- end of banner row -->
+<tr><!-- start of sidebar/body row -->
 <!-- start of sidebar cells -->
-<TD WIDTH=150 VALIGN=TOP BGCOLOR="#cccccc">
+<td width="150" valign="top" bgcolor="#cccccc" class="sidebar">
 <!-- start of sidebar table -->
-<TABLE WIDTH="100%" BORDER=0 CELLSPACING=0 CELLPADDING=3
-       BGCOLOR="#ffffff">
-<TR><TD BGCOLOR="#191970"><B><FONT COLOR="#ffffff">
+<table width="100%" border="0" cellspacing="0" cellpadding="3"
+       bgcolor="#ffffff">
+<tr><td bgcolor="#191970"><b><font color="#ffffff">
 Overview
-</FONT></B></TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="index.html">Introduction</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="history.html">History</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="features.html">Features</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="results.html">Results &amp; Testimonials</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="inuse.html">TMDA In Use</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="press.html">Press Coverage</A><!-- -*- html -*- -->
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">&nbsp;
-<TR><TD BGCOLOR="#191970"><B><FONT COLOR="#ffffff">
+</font></b></td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="index.html">Introduction</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="history.html">History</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="features.html">Features</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="results.html">Results &amp; Testimonials</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="inuse.html">TMDA In Use</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="press.html">Press Coverage</a><!-- -*- html -*- -->
+</td></tr>
+<tr><td bgcolor="#cccccc">&nbsp;
+<tr><td bgcolor="#191970"><b><font color="#ffffff">
 Install
-</FONT></B></TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="requirements.html">Requirements</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="download.html">Download</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="install.html">Installation</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">&nbsp;
-<TR><TD BGCOLOR="#191970"><B><FONT COLOR="#ffffff">
+</font></b></td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="requirements.html">Requirements</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="download.html">Download</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="install.html">Installation</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">&nbsp;
+<tr><td bgcolor="#191970"><b><font color="#ffffff">
 Configuration
-</FONT></B></TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="config.html">Overview</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="config-pre.html">Pre-Configuration</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="config-server.html">Server Configuration</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="config-client.html">Client Configuration</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
+</font></b></td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="config.html">Overview</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="config-pre.html">Pre-Configuration</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="config-server.html">Server Configuration</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="config-client.html">Client Configuration</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
 <b>Configuration Variables</b>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="config-filter.html">Filter Specification</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="filter-sources.html">Filter Sources</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">&nbsp;
-<TR><TD BGCOLOR="#191970"><B><FONT COLOR="#ffffff">
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="config-filter.html">Filter Specification</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="filter-sources.html">Filter Sources</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">&nbsp;
+<tr><td bgcolor="#191970"><b><font color="#ffffff">
 HOWTOs
-</FONT></B></TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="howtos.html">Overview</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="howto-template.html">Templates</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="tmda-ofmipd.html">tmda-ofmipd</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="tmda-vdomains.html">Virtual Domains</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="tmda-cgi.html">tmda-cgi</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">&nbsp;
-<TR><TD BGCOLOR="#191970"><B><FONT COLOR="#ffffff">
+</font></b></td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="howtos.html">Overview</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="howto-template.html">Templates</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="tmda-ofmipd.html">tmda-ofmipd</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="tmda-vdomains.html">Virtual Domains</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="tmda-cgi.html">tmda-cgi</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">&nbsp;
+<tr><td bgcolor="#191970"><b><font color="#ffffff">
 Support
-</FONT></B></TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="trouble.html">Troubleshooting</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
+</font></b></td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="trouble.html">Troubleshooting</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
 <a href="http://tmda.net/faq.cgi"; TARGET="Resource Window">FAQ</a>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="bugs.html">Bugs &amp; Patches</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="bugs.html">Bugs &amp; Patches</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
 <a href="http://tmda.net/lists/listinfo/"; TARGET="Resource Window">Mailing Lists</a>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
+</td></tr>
+<tr><td bgcolor="#cccccc">
 <a href="http://mla.libertine.org/"; TARGET="Resource Window">List Archive</a> 
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="support-commercial.html">Commercial Support</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="resources.html">External Resources</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="mirrors.html">Mirrors</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">&nbsp;
-<TR><TD BGCOLOR="#191970"><B><FONT COLOR="#ffffff">
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="support-commercial.html">Commercial Support</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="resources.html">External Resources</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="mirrors.html">Mirrors</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">&nbsp;
+<tr><td bgcolor="#191970"><b><font color="#ffffff">
 Author
-</FONT></B></TD></TR>
-<TR><TD BGCOLOR="#cccccc">
-<A HREF="mailto:[EMAIL PROTECTED]">Jason R. Mastaler</A>
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
+</font></b></td></tr>
+<tr><td bgcolor="#cccccc">
+<a href="mailto:[EMAIL PROTECTED]">Jason R. Mastaler</a>
+</td></tr>
+<tr><td bgcolor="#cccccc">
 &nbsp;
-</TD></TR>
-<TR><TD BGCOLOR="#cccccc">
+</td></tr>
+<tr><td bgcolor="#cccccc">
 &copy; 2001-2003
-</TD></TR>
-</TABLE><!-- end of sidebar table -->
+</td></tr>
+</table><!-- end of sidebar table -->
 
-</TD>
-<TD WIDTH=15>&nbsp;&nbsp;</TD><!--spacer-->
+</td>
+<td width="15">&nbsp;&nbsp;</td><!--spacer-->
 <!-- end of sidebar cell -->
 <!-- start of body cell -->
-<TD VALIGN=TOP WIDTH="90%"><BR>
+<td valign="top" width="90%" class="body"><br>
 <h3>TMDA Configuration Variables</h3>
 
 <ul>
@@ -325,77 +330,87 @@
 <td><a href="#MESSAGE_TAG_HEADER_STYLE">MESSAGE_TAG_HEADER_STYLE</a></td>
 </tr>
 <tr>
+<td><a href="#MYSQL_DATABASE">MYSQL_DATABASE</a></td>
+<td><a href="#MYSQL_ENABLED">MYSQL_ENABLED</a></td>
+</tr>
+<tr>
+<td><a href="#MYSQL_HOST">MYSQL_HOST</a></td>
+<td><a href="#MYSQL_PASSWORD">MYSQL_PASSWORD</a></td>
+</tr>
+<tr>
+<td><a href="#MYSQL_USER">MYSQL_USER</a></td>
 <td><a href="#OUTGOINGMAIL">OUTGOINGMAIL</a></td>
-<td><a href="#PENDING_BLACKLIST_APPEND">PENDING_BLACKLIST_APPEND</a></td>
 </tr>
 <tr>
+<td><a href="#PENDING_BLACKLIST_APPEND">PENDING_BLACKLIST_APPEND</a></td>
 <td><a href="#PENDING_CACHE">PENDING_CACHE</a></td>
-<td><a href="#PENDING_CACHE_LEN">PENDING_CACHE_LEN</a></td>
 </tr>
 <tr>
+<td><a href="#PENDING_CACHE_LEN">PENDING_CACHE_LEN</a></td>
 <td><a href="#PENDING_DELETE_APPEND">PENDING_DELETE_APPEND</a></td>
-<td><a href="#PENDING_RELEASE_APPEND">PENDING_RELEASE_APPEND</a></td>
 </tr>
 <tr>
+<td><a href="#PENDING_RELEASE_APPEND">PENDING_RELEASE_APPEND</a></td>
 <td><a href="#PENDING_WHITELIST_APPEND">PENDING_WHITELIST_APPEND</a></td>
-<td><a href="#PRIMARY_ADDRESS_MATCH">PRIMARY_ADDRESS_MATCH</a></td>
 </tr>
 <tr>
+<td><a href="#PRIMARY_ADDRESS_MATCH">PRIMARY_ADDRESS_MATCH</a></td>
 <td><a href="#PURGED_HEADERS">PURGED_HEADERS</a></td>
-<td><a href="#RECIPIENT_DELIMITER">RECIPIENT_DELIMITER</a></td>
 </tr>
 <tr>
+<td><a href="#RECIPIENT_DELIMITER">RECIPIENT_DELIMITER</a></td>
 <td><a href="#RECIPIENT_HEADER">RECIPIENT_HEADER</a></td>
-<td><a href="#RESPONSE_DIR">RESPONSE_DIR</a></td>
 </tr>
 <tr>
+<td><a href="#RESPONSE_DIR">RESPONSE_DIR</a></td>
 <td><a href="#SENDER_TEMPLATE_VARS">SENDER_TEMPLATE_VARS</a></td>
-<td><a href="#SENDMAIL_PROGRAM">SENDMAIL_PROGRAM</a></td>
 </tr>
 <tr>
+<td><a href="#SENDMAIL_PROGRAM">SENDMAIL_PROGRAM</a></td>
 <td><a href="#SMTPAUTH_PASSWORD">SMTPAUTH_PASSWORD</a></td>
-<td><a href="#SMTPAUTH_USERNAME">SMTPAUTH_USERNAME</a></td>
 </tr>
 <tr>
+<td><a href="#SMTPAUTH_USERNAME">SMTPAUTH_USERNAME</a></td>
 <td><a href="#SMTPHOST">SMTPHOST</a></td>
-<td><a href="#SMTPSSL">SMTPSSL</a></td>
 </tr>
 <tr>
+<td><a href="#SMTPSSL">SMTPSSL</a></td>
 <td><a href="#SMTPSSL_CERTFILE">SMTPSSL_CERTFILE</a></td>
-<td><a href="#SMTPSSL_KEYFILE">SMTPSSL_KEYFILE</a></td>
 </tr>
 <tr>
+<td><a href="#SMTPSSL_KEYFILE">SMTPSSL_KEYFILE</a></td>
 <td><a 
href="#SMTP_MAX_SESSIONS_PER_CONNECTION">SMTP_MAX_SESSIONS_PER_CONNECTION</a></td>
-<td><a href="#SUMMARY_HEADERS">SUMMARY_HEADERS</a></td>
 </tr>
 <tr>
+<td><a href="#SUMMARY_HEADERS">SUMMARY_HEADERS</a></td>
 <td><a href="#TAGS_CONFIRM">TAGS_CONFIRM</a></td>
-<td><a href="#TAGS_DATED">TAGS_DATED</a></td>
 </tr>
 <tr>
+<td><a href="#TAGS_DATED">TAGS_DATED</a></td>
 <td><a href="#TAGS_KEYWORD">TAGS_KEYWORD</a></td>
-<td><a href="#TAGS_SENDER">TAGS_SENDER</a></td>
 </tr>
 <tr>
+<td><a href="#TAGS_SENDER">TAGS_SENDER</a></td>
 <td><a href="#TEMPLATE_DIR">TEMPLATE_DIR</a></td>
-<td><a href="#TEMPLATE_DIR_MATCH_SENDER">TEMPLATE_DIR_MATCH_SENDER</a></td>
 </tr>
 <tr>
+<td><a href="#TEMPLATE_DIR_MATCH_SENDER">TEMPLATE_DIR_MATCH_SENDER</a></td>
 <td><a href="#TEMPLATE_EMAIL_HEADERS">TEMPLATE_EMAIL_HEADERS</a></td>
-<td><a href="#TEMPLATE_ENCODED_HEADERS">TEMPLATE_ENCODED_HEADERS</a></td>
 </tr>
 <tr>
+<td><a href="#TEMPLATE_ENCODED_HEADERS">TEMPLATE_ENCODED_HEADERS</a></td>
 <td><a href="#TERSE_SUMMARY_HEADERS">TERSE_SUMMARY_HEADERS</a></td>
-<td><a href="#TIMEOUT">TIMEOUT</a></td>
 </tr>
 <tr>
+<td><a href="#TIMEOUT">TIMEOUT</a></td>
 <td><a href="#USERNAME">USERNAME</a></td>
-<td><a href="#USEVIRTUALDOMAINS">USEVIRTUALDOMAINS</a></td>
 </tr>
 <tr>
+<td><a href="#USEVIRTUALDOMAINS">USEVIRTUALDOMAINS</a></td>
 <td><a href="#VIRTUALDOMAINS">VIRTUALDOMAINS</a></td>
-<td><a href="#X_TMDA_IN_SUBJECT">X_TMDA_IN_SUBJECT</a></td>
 </tr>
+<tr>
+<td><a href="#X_TMDA_IN_SUBJECT">X_TMDA_IN_SUBJECT</a></td>
 </table>
 
 <dl>
@@ -1231,6 +1246,63 @@
 The valid values and default value is identical to that of
 MESSAGE_FROM_STYLE.
 <dt><hr>
+<a name="MYSQL_DATABASE"><h4>MYSQL_DATABASE</h4></a>
+<dd>
+MySQL database containing any lists used in filter.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_DATABASE = "JimsTMDA"</code>
+<br><br>
+Default is "TMDA".
+<dt><hr>
+<a name="MYSQL_ENABLED"><h4>MYSQL_ENABLED</h4></a>
+<dd>
+All defaults beginning with "MYSQL_" configure the use of a MySQL
+database in the filtering process.  To use a MySQL database, you
+must have the _mysql library loaded.  See:
+<br>
+http://sourceforge.net/projects/mysql-python/
+<br><br>
+MYSQL_ENABLED must be set to 1 if you wish to use a MySQL database
+in your filters.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_ENABLED = 1</code>
+<br><br>
+Default is 0 (disabled)
+<dt><hr>
+<a name="MYSQL_HOST"><h4>MYSQL_HOST</h4></a>
+<dd>
+MySQL host to connect to.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_HOST = "db.my.server"</code>
+<br><br>
+Default is "localhost".
+<dt><hr>
+<a name="MYSQL_PASSWORD"><h4>MYSQL_PASSWORD</h4></a>
+<dd>
+MySQL password to use when connecting to database.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_USER = "[EMAIL PROTECTED]"</code>
+<br><br>
+Default is "".
+<dt><hr>
+<a name="MYSQL_USER"><h4>MYSQL_USER</h4></a>
+<dd>
+MySQL user to use when connecting to database.
+<br><br>
+Example:
+<br><br>
+<code>MYSQL_USER = "Jim"</code>
+<br><br>
+Default is "TMDA".
+<dt><hr>
 <a name="OUTGOINGMAIL"><h4>OUTGOINGMAIL</h4></a>
 <dd>
 Final delivery method for all outgoing mail (server and client).
@@ -1711,7 +1783,7 @@
 Default is 0 (turned off)
 </dl>
 
-</TD><!-- end of body cell -->
-</TR><!-- end of sidebar/body row -->
-</TABLE><!-- end of page table -->
-</BODY></HTML>
+</td><!-- end of body cell -->
+</tr><!-- end of sidebar/body row -->
+</table><!-- end of page table -->
+</body></html>

Index: filter-sources.ht
===================================================================
RCS file: /cvsroot/tmda/tmda/htdocs/filter-sources.ht,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- filter-sources.ht   12 Mar 2003 21:12:09 -0000      1.4
+++ filter-sources.ht   23 Mar 2003 23:23:54 -0000      1.5
@@ -25,165 +25,120 @@
 The <code>to-*</code> sources examine the envelope recipient address but
 <i>not</i> the To header field, which is often bogus in spam email.
 <br><br>
-
 <dl>
-<dt>
-<code>
-from <a href="#email_address">&lt;email_address&gt;</a><br>
-to <a href="#email_address">&lt;email_address&gt;</a>
-</code>
-<dd>
-
-The <code>from</code> and <code>to</code> sources expect a match field
-of either an explicit email address or a wildcarded email address.
-The format of the email address is documented <a
-href="#email_address">below</a>.
-
-<br><br>
-
-<dt>
-<code>
-from-file [ <a href="#autoflags">-autocdb</a> |
-            <a href="#autoflags">-autodbm</a> ] [ -optional ]
-          <a href="#email_file">&lt;textfile&gt;</a><br>
-to-file [ <a href="#autoflags">-autocdb</a> |
-          <a href="#autoflags">-autodbm</a> ] [ -optional ]
-          <a href="#email_file">&lt;textfile&gt;</a>
-</code>
-<dd>
-
-The <code>from-file</code> and <code>to-file</code> sources expect the
-name of a textfile as the match field.  You can specify the entire
-path explicitly or use a leading '~' to represent the user's home
-directory, like the shell does.  The match field is always the name of
-the textfile.  You do not need to add '.cdb' or '.db' if you use the
-<code>-auto*</code> flags. It will be automatically appended to the
-filename.  The format of the textfile is documented <a
-href="#email_file">below</a>.
-
-<br><br>
-
-Both <code>from-file</code> and <code>to-file</code> can take one of
-the <code>-autocdb</code> or <code>-autodbm flags</code>.  The
--autocdb and -autodbm flags are documented <a
-href="#autoflags">below</a>.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-
-<dt>
-<code>
-from-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a><br>
-to-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a>
-</code>
-<dd>
-
-The <code>from-cdb</code> and <code>to-cdb</code> sources expect a
-match field of a CDB database filename.  You can specify the entire
-path or use a leading '~' to represent the user's home directory.  You
-should specify the <b>.cdb</b> extension as part of the filename.  The
-CDB format and expected contents are documented <a
-href="#db_file">below</a>.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-<dt>
-<code>
-from-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a><br>
-to-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a>
-</code>
-<dd>
-
-The <code>from-dbm</code> and <code>to-dbm</code> sources expect the
-name of a DBM database in the match field.  You can specify the entire
-path or use a leading '~' to represent the user's home directory.  You
-should specify the <b>.db</b> extension as part of the filename.  The
-DBM format and expected contents are documented <a
-href="#db_file">below</a>.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-
-<dt>
-<code>
-from-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt;<br>
-to-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt;
-</code>
-<dd>
-
-The <code>from-ezmlm</code> and <code>to-ezmlm</code> sources match
-against the subscriber list of an <a href="http://cr.yp.to/ezmlm.html";
-TARGET="Resource Window">ezmlm</a> mailing list.  They expect the
-match field to be the full path of the <i>parent</i> directory of an
-ezmlm `subscribers' directory.  You should not include the
-`subscribers' portion of the path.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-
-<dt>
-<code>
-from-mailman -attr=&lt;attribute&gt; [ -optional ] &lt;path_to_list_dir&gt;<br>
-to-mailman -attr=&lt;attribute&gt; [ -optional ] &lt;path_to_list_dir&gt;
-</code>
-<dd>
-
-The <code>from-mailman</code> and <code>to-mailman</code> sources
-match against addresses contained in a <a href="http://list.org/";
-TARGET="Resource Window">Mailman</a> configuration database.  The
-match field should be the full path to the list directory.  Both
-Mailman 2.0 and 2.1-style configuration databases are supported.
-
-<br><br>
-
-The <code>-mailman</code> sources require you to specify an
-`attribute' to search.  Use the <code>-attr=attribute</code> flag to
-specify the name of an attribute contained in the database.  For
-example, `members' (subscriber addresses), `digest_members' (digest
-subscriber addresses), or `owner' (list owner's address).
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
+  <dt> <code> from <a href="#email_address">&lt;email_address&gt;</a><br>
+    to <a href="#email_address">&lt;email_address&gt;</a> </code> 
+  <dd> The <code>from</code> and <code>to</code> sources expect a match field 
+    of either an explicit email address or a wildcarded email address. The format 
+    of the email address is documented <a
+href="#email_address">below</a>. <br>
+    <br>
+  <dt> <code> from-file [ <a href="#autoflags">-autocdb</a> | <a 
href="#autoflags">-autodbm</a> 
+    ] [ -optional ] <a href="#email_file">&lt;textfile&gt;</a><br>
+    to-file [ <a href="#autoflags">-autocdb</a> | <a href="#autoflags">-autodbm</a> 
+    ] [ -optional ] <a href="#email_file">&lt;textfile&gt;</a> </code> 
+  <dd> The <code>from-file</code> and <code>to-file</code> sources expect the 
+    name of a textfile as the match field. You can specify the entire path explicitly 
+    or use a leading '~' to represent the user's home directory, like the shell 
+    does. The match field is always the name of the textfile. You do not need 
+    to add '.cdb' or '.db' if you use the <code>-auto*</code> flags. It will be 
+    automatically appended to the filename. The format of the textfile is documented 
+    <a
+href="#email_file">below</a>. <br>
+    <br>
+    Both <code>from-file</code> and <code>to-file</code> can take one of the 
<code>-autocdb</code> 
+    or <code>-autodbm flags</code>. The -autocdb and -autodbm flags are documented 
+    <a
+href="#autoflags">below</a>. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a><br>
+    to-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a> </code> 
+  <dd> The <code>from-cdb</code> and <code>to-cdb</code> sources expect a match 
+    field of a CDB database filename. You can specify the entire path or use a 
+    leading '~' to represent the user's home directory. You should specify the 
+    <b>.cdb</b> extension as part of the filename. The CDB format and expected 
+    contents are documented <a
+href="#db_file">below</a>. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a><br>
+    to-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a> </code> 
+  <dd> The <code>from-dbm</code> and <code>to-dbm</code> sources expect the name 
+    of a DBM database in the match field. You can specify the entire path or use 
+    a leading '~' to represent the user's home directory. You should specify the 
+    <b>.db</b> extension as part of the filename. The DBM format and expected 
+    contents are documented <a
+href="#db_file">below</a>. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt;<br>
+    to-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt; </code> 
+  <dd> The <code>from-ezmlm</code> and <code>to-ezmlm</code> sources match against 
+    the subscriber list of an <a href="http://cr.yp.to/ezmlm.html";
+TARGET="Resource Window">ezmlm</a> mailing list. They expect the match field to 
+    be the full path of the <i>parent</i> directory of an ezmlm `subscribers' 
+    directory. You should not include the `subscribers' portion of the path. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-mailman -attr=&lt;attribute&gt; [ -optional ] 
&lt;path_to_list_dir&gt;<br>
+    to-mailman -attr=&lt;attribute&gt; [ -optional ] &lt;path_to_list_dir&gt; 
+    </code> 
+  <dd> The <code>from-mailman</code> and <code>to-mailman</code> sources match 
+    against addresses contained in a <a href="http://list.org/";
+TARGET="Resource Window">Mailman</a> configuration database. The match field should 
+    be the full path to the list directory. Both Mailman 2.0 and 2.1-style 
configuration 
+    databases are supported. <br>
+    <br>
+    The <code>-mailman</code> sources require you to specify an `attribute' to 
+    search. Use the <code>-attr=attribute</code> flag to specify the name of an 
+    attribute contained in the database. For example, `members' (subscriber 
addresses), 
+    `digest_members' (digest subscriber addresses), or `owner' (list owner's 
address). 
+    <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-mysql [ -like | -rlike ] &lt;table&gt;<br>
+    to-mysql [ -like | -rlike ] &lt;table&gt; </code> 
+  <dd> The <code>from-mysql</code> and <code>to-mysql</code> sources match against 
+    addresses contained in a <a href="http://mysql.org/";
+TARGET="Resource Window">MySQL</a> database table. The match field should be the 
+    table name. The MySQL host, user name, password, and database name should 
+    all be configured with the appropriate <a href="config-vars.html"
+TARGET="Resource Window">MYSQL_*</a> variable. The MySQL table format and expected 
+    contents are documented <a href="#MySQL">below</a>.<br>
+    <br>
+    If no flags are specified, the address(es) being tested must exactly match 
+    an entry in the table. Wildcard matching may be done by adding the 
<code>-like</code> 
+    or <code>-rlike</code> flags. <code>-like</code> indicates that MySQL 
<code>LIKE</code> 
+    comparison should be done (i.e. <code>[EMAIL PROTECTED]</code> would match all 
+    users in the <code>my.host.name</code> domain). <code>-rlike</code> indicates 
+    that MySQL regular expression (<code>RLIKE</code>) comparison should be done 
+    (i.e. <code>[EMAIL PROTECTED]</code> would match all users in the 
<code>my.host.name</code> 
+    domain).<br>
+    <br>
 </dl>
-
-The following group of sources may be used only in incoming filter
-files.
-<br><br>
+The following group of sources may be used only in incoming filter files. <br>
+<br>
 
 <dl>
 <dt>
@@ -284,41 +239,23 @@
 <h3>Miscellaneous Notes</h3>
 
 <dl>
-<dt>
-<a name="email_address"><b>Email Addresses</b></a>
-<dd>
-
-In addition to explicit email addresses, you can use expressions
-based on UNIX shell-style wildcard characters anywhere an email
-address is expected.
-
-<br><br>
-
-<strong>NOTE:</strong> Wildcard characters are not recognized in a CDB
-or DBM file.
-
-<br><br>
-
-The special characters are:
-
-<blockquote><pre>
-
-Characters(s)    Description
--------------    -----------
-*                Matches everything.
-?                Matches any single character.
-[seq]            Matches any character in seq.
-[!seq]           Matches any character not in seq.
-
-</blockquote></pre>
-
-In addition, `<code>@=</code>' (a custom rule) will expand to match
-both <code>@</code> and <code>@*.</code>
-
-<br><br>
-
-Here are some common examples:
-<pre><blockquote>
+  <dt> <a name="email_address"><b>Email Addresses</b></a> 
+  <dd> In addition to explicit email addresses, you can use expressions based 
+    on UNIX shell-style wildcard characters anywhere an email address is expected. 
+    <br>
+    <br>
+    <strong>NOTE:</strong> Wildcard characters are not recognized in a CDB or 
+    DBM file. <br>
+    <br>
+    The special characters are: 
+    <blockquote><pre> Characters(s) Description ------------- ----------- * Matches 
+      everything. ? Matches any single character. [seq] Matches any character 
+      in seq. [!seq] Matches any character not in seq. </blockquote></pre>
+    In addition, `<code>@=</code>' (a custom rule) will expand to match both 
<code>@</code> 
+    and <code>@*.</code> <br>
+    <br>
+    Here are some common examples: 
+    <pre><blockquote>
 # match only [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 # match [EMAIL PROTECTED], but not [EMAIL PROTECTED]
@@ -329,113 +266,105 @@
 [EMAIL PROTECTED]
 
 </blockquote></pre>
-<strong>NOTE:</strong> To match the empty envelope sender such as bounce
-messages are sent with, use <b><code><></code></b> as the expression.
-
-<br><br>
-
-<dt>
-<a name="email_file"><b>Email Address Files</b></a>
-<dd>
-
-Email address files are textfiles containing an email address on each
-line.  When using the <code>from-file</code> and <code>to-file</code>
-sources, the textfile is searched sequentially, with the first match
-terminating the search.  Wildcarded email addresses are supported in
-textfiles.
-
-<br><br>
-
-Address files may contain an optional second field on each line that
-specifies an action (<code>ok, drop, bounce, etc.</code>).  If the
-action is specified, it overrides the action given in the filter rule.
-
-<br><br>
-
-<dt>
-<a name="autoflags"><b>Auto- Database Flags</b></a>
-<dd>
-
-If you have lengthy email address textfiles, you might want to
-consider using the much faster hashed databases instead.  The address
-files used by the auto-building hashed database feature are the same
-email address textfiles documented above with the sole exception that
-wildcards are not supported.
-
-<br><br>
-
-The <code>-autocdb</code> and <code>-autodbm</code> arguments are
-intended to ease the use of CDB/DBM lists in TMDA by automatically
-rebuilding the CDB or DBM file as necessary.  This gives you the
-performance advantages of hashed databases without the hassle of
-having to manually maintain them.  With the <code>-auto*</code>
-arguments, TMDA will rebuild the database if it doesn't exist or if
-its timestamp is older than its source file.  If the rebuild fails for
-some reason, TMDA will fall back to matching from the textfile
-instead.
-
-<br><br>
-
-Before you try the CDB version of this feature, make sure you have the
-<a href="http://pilcrow.madison.wi.us/#pycdb"; TARGET="Resource
-Window">python-cdb</a> extension module installed.
-
-<br><br>
-
-<dt>
-<a name="db_file"><b>Database Files</b></a>
-<dd>
-
-CDB and DBM files are hashed databases.  TMDA can look up email
-addresses in these files.  Lookup in these files is much
-faster than in a textfile.  On the other hand, wildcards are not
-supported in database files -- only in textfiles.
-
-<br><br>
-
-In a CDB or DBM, the keys should be the email addresses to match, and
-their corresponding values (or records) should be empty unless you
-want to override the action specified in the filter file.
-
-<br><br>
-
-CDB or DBM files can be created outside of TMDA and merely referenced
-by your filter files (use the <code>*-cdb</code> and
-<code>*-dbm</code> filter rules) or can be automatically created by
-TMDA if you use the <code>-autocdb</code> or <code>-autodbm</code>
-flags and the <code>*-file</code> rules.
-
-<br><br>
-
-If you wish to explore CDB databases, make sure you have the <a
+    <strong>NOTE:</strong> To match the empty envelope sender such as bounce messages 
+    are sent with, use <b><code><></code></b> as the expression. <br>
+    <br>
+  <dt> <a name="email_file"><b>Email Address Files</b></a> 
+  <dd> Email address files are textfiles containing an email address on each line. 
+    When using the <code>from-file</code> and <code>to-file</code> sources, the 
+    textfile is searched sequentially, with the first match terminating the search. 
+    Wildcarded email addresses are supported in textfiles. <br>
+    <br>
+    Address files may contain an optional second field on each line that specifies 
+    an action (<code>ok, drop, bounce, etc.</code>). If the action is specified, 
+    it overrides the action given in the filter rule. <br>
+    <br>
+  <dt> <a name="autoflags"><b>Auto- Database Flags</b></a> 
+  <dd> If you have lengthy email address textfiles, you might want to consider 
+    using the much faster hashed databases instead. The address files used by 
+    the auto-building hashed database feature are the same email address textfiles 
+    documented above with the sole exception that wildcards are not supported. 
+    <br>
+    <br>
+    The <code>-autocdb</code> and <code>-autodbm</code> arguments are intended 
+    to ease the use of CDB/DBM lists in TMDA by automatically rebuilding the CDB 
+    or DBM file as necessary. This gives you the performance advantages of hashed 
+    databases without the hassle of having to manually maintain them. With the 
+    <code>-auto*</code> arguments, TMDA will rebuild the database if it doesn't 
+    exist or if its timestamp is older than its source file. If the rebuild fails 
+    for some reason, TMDA will fall back to matching from the textfile instead. 
+    <br>
+    <br>
+    Before you try the CDB version of this feature, make sure you have the <a 
href="http://pilcrow.madison.wi.us/#pycdb"; TARGET="Resource
+Window">python-cdb</a> extension module installed. <br>
+    <br>
+  <dt> <a name="db_file"><b>Database Files</b></a> 
+  <dd> CDB and DBM files are hashed databases. TMDA can look up email addresses 
+    in these files. Lookup in these files is much faster than in a textfile. On 
+    the other hand, wildcards are not supported in database files -- only in 
textfiles. 
+    <br>
+    <br>
+    In a CDB or DBM, the keys should be the email addresses to match, and their 
+    corresponding values (or records) should be empty unless you want to override 
+    the action specified in the filter file. <br>
+    <br>
+    CDB or DBM files can be created outside of TMDA and merely referenced by your 
+    filter files (use the <code>*-cdb</code> and <code>*-dbm</code> filter rules) 
+    or can be automatically created by TMDA if you use the <code>-autocdb</code> 
+    or <code>-autodbm</code> flags and the <code>*-file</code> rules. <br>
+    <br>
+    If you wish to explore CDB databases, make sure you have the <a
 href="http://pilcrow.madison.wi.us/#pycdb"; TARGET="Resource
-Window">python-cdb</a> extension module installed.
-
-<br><br>
-
-<dt>
-<a name="re_file"><b>Regular Expression Files</b></a>
-<dd>
-
-A regular expression textfile is simply a text file with a regular
-expression on each line.  The file is read sequentially and each
-regular expression is used to attempt a match.  As soon as there is a
-match, the search stops.
-
-<br><br>
-
-Because regular expressions may include spaces, you must surround the
-regular expressions with quotation marks.  You may use either single
-quotes (<code><b>'</b></code>) or double quotes
-(<code><b>"</b></code>) as long as you use the the same one at both
-the beginning and the end.
-
-<br><br>
-
-If you need to match a quote in your regular expression, simply use
-the other style of quotes to surround the expression or escape the
-embedded quote with a backslash (<code><b>\</b></code>).
-<br><br>
-
+Window">python-cdb</a> extension module installed. <br>
+    <br>
+  <dt> <a name="MySQL" id="MySQL"><b>MySQL Tables</b></a> 
+  <dd> MySQL tables used in <code>from-mysql</code> and <code>to-mysql</code> 
+    filter sources should be created with the following SQL: 
+    <p> 
+    <pre>CREATE TABLE &lt;table_name&gt;
+(
+    ADDRESS text NOT NULL,
+    ACTION text NOT NULL,
+    PRIMARY KEY (ADDRESS(80))
+)</pre>
+    The <code>ACTION</code> field in your records may generally be left blank, 
+    but if present, any command in the field will override the action specified 
+    in the filter source. In other words: 
+    <pre>+-------------+--------+
+| ADDRESS     | ACTION |
++-------------+--------+
+| [EMAIL PROTECTED] | bounce |
++-------------+--------+</pre>
+    will cause all mail from yahoo.com to bounce, even if the filter source was: 
+    <pre>from-mysql -like TMDA accept</pre>
+    Make sure that the MySQL user specified in <a 
href="config-vars.html#MYSQL_USER"><code>MYSQL_USER</code></a> 
+    has been <code>GRANT</code>ed sufficient <code>SELECT</code> privileges to 
+    allow access to the table listed in your filter source.<br>
+    <br>
+    The TMDA filter parser will stop on the first matching record found. If you 
+    are using the <code>-like</code> or <code>-rlike</code> options and multiple 
+    table entries match, there is no predicting which record will be used.<br>
+    <br>
+    If you wish to explore MySQL databases, make sure you have the <a
+href="http://sourceforge.net/projects/mysql-python/"; TARGET="Resource
+Window">mysql-python</a> extension module installed. <br>
+    <br></dt>
+    
+  <dd></dt> 
+  <dd></dt> 
+  <dt> <a name="re_file"><b>Regular Expression Files</b></a> 
+  <dd> A regular expression textfile is simply a text file with a regular expression 
+    on each line. The file is read sequentially and each regular expression is 
+    used to attempt a match. As soon as there is a match, the search stops. <br>
+    <br>
+    Because regular expressions may include spaces, you must surround the regular 
+    expressions with quotation marks. You may use either single quotes 
(<code><b>'</b></code>) 
+    or double quotes (<code><b>"</b></code>) as long as you use the the same one 
+    at both the beginning and the end. <br>
+    <br>
+    If you need to match a quote in your regular expression, simply use the other 
+    style of quotes to surround the expression or escape the embedded quote with 
+    a backslash (<code><b>\</b></code>). <br>
+    <br>
 </dl>
 

Index: filter-sources.html
===================================================================
RCS file: /cvsroot/tmda/tmda/htdocs/filter-sources.html,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- filter-sources.html 12 Mar 2003 21:12:21 -0000      1.13
+++ filter-sources.html 23 Mar 2003 23:23:54 -0000      1.14
@@ -1,7 +1,7 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 <html>
 <!-- THIS PAGE IS AUTOMATICALLY GENERATED.  DO NOT EDIT. -->
-<!-- Wed Mar 12 15:01:19 2003 -->
+<!-- Sun Mar 23 17:22:56 2003 -->
 <!-- USING HT2HTML 2.0 -->
 <!-- SEE http://ht2html.sf.net -->
 <!-- User-specified headers:
@@ -210,165 +210,120 @@
 The <code>to-*</code> sources examine the envelope recipient address but
 <i>not</i> the To header field, which is often bogus in spam email.
 <br><br>
-
 <dl>
-<dt>
-<code>
-from <a href="#email_address">&lt;email_address&gt;</a><br>
-to <a href="#email_address">&lt;email_address&gt;</a>
-</code>
-<dd>
-
-The <code>from</code> and <code>to</code> sources expect a match field
-of either an explicit email address or a wildcarded email address.
-The format of the email address is documented <a
-href="#email_address">below</a>.
-
-<br><br>
-
-<dt>
-<code>
-from-file [ <a href="#autoflags">-autocdb</a> |
-            <a href="#autoflags">-autodbm</a> ] [ -optional ]
-          <a href="#email_file">&lt;textfile&gt;</a><br>
-to-file [ <a href="#autoflags">-autocdb</a> |
-          <a href="#autoflags">-autodbm</a> ] [ -optional ]
-          <a href="#email_file">&lt;textfile&gt;</a>
-</code>
-<dd>
-
-The <code>from-file</code> and <code>to-file</code> sources expect the
-name of a textfile as the match field.  You can specify the entire
-path explicitly or use a leading '~' to represent the user's home
-directory, like the shell does.  The match field is always the name of
-the textfile.  You do not need to add '.cdb' or '.db' if you use the
-<code>-auto*</code> flags. It will be automatically appended to the
-filename.  The format of the textfile is documented <a
-href="#email_file">below</a>.
-
-<br><br>
-
-Both <code>from-file</code> and <code>to-file</code> can take one of
-the <code>-autocdb</code> or <code>-autodbm flags</code>.  The
--autocdb and -autodbm flags are documented <a
-href="#autoflags">below</a>.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-
-<dt>
-<code>
-from-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a><br>
-to-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a>
-</code>
-<dd>
-
-The <code>from-cdb</code> and <code>to-cdb</code> sources expect a
-match field of a CDB database filename.  You can specify the entire
-path or use a leading '~' to represent the user's home directory.  You
-should specify the <b>.cdb</b> extension as part of the filename.  The
-CDB format and expected contents are documented <a
-href="#db_file">below</a>.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-<dt>
-<code>
-from-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a><br>
-to-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a>
-</code>
-<dd>
-
-The <code>from-dbm</code> and <code>to-dbm</code> sources expect the
-name of a DBM database in the match field.  You can specify the entire
-path or use a leading '~' to represent the user's home directory.  You
-should specify the <b>.db</b> extension as part of the filename.  The
-DBM format and expected contents are documented <a
-href="#db_file">below</a>.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-
-<dt>
-<code>
-from-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt;<br>
-to-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt;
-</code>
-<dd>
-
-The <code>from-ezmlm</code> and <code>to-ezmlm</code> sources match
-against the subscriber list of an <a href="http://cr.yp.to/ezmlm.html";
-TARGET="Resource Window">ezmlm</a> mailing list.  They expect the
-match field to be the full path of the <i>parent</i> directory of an
-ezmlm `subscribers' directory.  You should not include the
-`subscribers' portion of the path.
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
-
-<dt>
-<code>
-from-mailman -attr=&lt;attribute&gt; [ -optional ] &lt;path_to_list_dir&gt;<br>
-to-mailman -attr=&lt;attribute&gt; [ -optional ] &lt;path_to_list_dir&gt;
-</code>
-<dd>
-
-The <code>from-mailman</code> and <code>to-mailman</code> sources
-match against addresses contained in a <a href="http://list.org/";
-TARGET="Resource Window">Mailman</a> configuration database.  The
-match field should be the full path to the list directory.  Both
-Mailman 2.0 and 2.1-style configuration databases are supported.
-
-<br><br>
-
-The <code>-mailman</code> sources require you to specify an
-`attribute' to search.  Use the <code>-attr=attribute</code> flag to
-specify the name of an attribute contained in the database.  For
-example, `members' (subscriber addresses), `digest_members' (digest
-subscriber addresses), or `owner' (list owner's address).
-
-<br><br>
-
-If the <code>-optional</code> flag is given, the non-existence of the
-file is not an error.  If the file should exist, don't specify this
-flag; the parser will log an error and will defer the mail so that you
-have a chance to fix the problem.
-
-<br><br>
-
+  <dt> <code> from <a href="#email_address">&lt;email_address&gt;</a><br>
+    to <a href="#email_address">&lt;email_address&gt;</a> </code> 
+  <dd> The <code>from</code> and <code>to</code> sources expect a match field 
+    of either an explicit email address or a wildcarded email address. The format 
+    of the email address is documented <a
+href="#email_address">below</a>. <br>
+    <br>
+  <dt> <code> from-file [ <a href="#autoflags">-autocdb</a> | <a 
href="#autoflags">-autodbm</a> 
+    ] [ -optional ] <a href="#email_file">&lt;textfile&gt;</a><br>
+    to-file [ <a href="#autoflags">-autocdb</a> | <a href="#autoflags">-autodbm</a> 
+    ] [ -optional ] <a href="#email_file">&lt;textfile&gt;</a> </code> 
+  <dd> The <code>from-file</code> and <code>to-file</code> sources expect the 
+    name of a textfile as the match field. You can specify the entire path explicitly 
+    or use a leading '~' to represent the user's home directory, like the shell 
+    does. The match field is always the name of the textfile. You do not need 
+    to add '.cdb' or '.db' if you use the <code>-auto*</code> flags. It will be 
+    automatically appended to the filename. The format of the textfile is documented 
+    <a
+href="#email_file">below</a>. <br>
+    <br>
+    Both <code>from-file</code> and <code>to-file</code> can take one of the 
<code>-autocdb</code> 
+    or <code>-autodbm flags</code>. The -autocdb and -autodbm flags are documented 
+    <a
+href="#autoflags">below</a>. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a><br>
+    to-cdb [ -optional ] <a href="#db_file">&lt;database.cdb&gt;</a> </code> 
+  <dd> The <code>from-cdb</code> and <code>to-cdb</code> sources expect a match 
+    field of a CDB database filename. You can specify the entire path or use a 
+    leading '~' to represent the user's home directory. You should specify the 
+    <b>.cdb</b> extension as part of the filename. The CDB format and expected 
+    contents are documented <a
+href="#db_file">below</a>. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a><br>
+    to-dbm [ -optional ] <a href="#db_file">&lt;database.db&gt;</a> </code> 
+  <dd> The <code>from-dbm</code> and <code>to-dbm</code> sources expect the name 
+    of a DBM database in the match field. You can specify the entire path or use 
+    a leading '~' to represent the user's home directory. You should specify the 
+    <b>.db</b> extension as part of the filename. The DBM format and expected 
+    contents are documented <a
+href="#db_file">below</a>. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt;<br>
+    to-ezmlm [ -optional ] &lt;path_to_subscribers_parent_dir&gt; </code> 
+  <dd> The <code>from-ezmlm</code> and <code>to-ezmlm</code> sources match against 
+    the subscriber list of an <a href="http://cr.yp.to/ezmlm.html";
+TARGET="Resource Window">ezmlm</a> mailing list. They expect the match field to 
+    be the full path of the <i>parent</i> directory of an ezmlm `subscribers' 
+    directory. You should not include the `subscribers' portion of the path. <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-mailman -attr=&lt;attribute&gt; [ -optional ] 
&lt;path_to_list_dir&gt;<br>
+    to-mailman -attr=&lt;attribute&gt; [ -optional ] &lt;path_to_list_dir&gt; 
+    </code> 
+  <dd> The <code>from-mailman</code> and <code>to-mailman</code> sources match 
+    against addresses contained in a <a href="http://list.org/";
+TARGET="Resource Window">Mailman</a> configuration database. The match field should 
+    be the full path to the list directory. Both Mailman 2.0 and 2.1-style 
configuration 
+    databases are supported. <br>
+    <br>
+    The <code>-mailman</code> sources require you to specify an `attribute' to 
+    search. Use the <code>-attr=attribute</code> flag to specify the name of an 
+    attribute contained in the database. For example, `members' (subscriber 
addresses), 
+    `digest_members' (digest subscriber addresses), or `owner' (list owner's 
address). 
+    <br>
+    <br>
+    If the <code>-optional</code> flag is given, the non-existence of the file 
+    is not an error. If the file should exist, don't specify this flag; the parser 
+    will log an error and will defer the mail so that you have a chance to fix 
+    the problem. <br>
+    <br>
+  <dt> <code> from-mysql [ -like | -rlike ] &lt;table&gt;<br>
+    to-mysql [ -like | -rlike ] &lt;table&gt; </code> 
+  <dd> The <code>from-mysql</code> and <code>to-mysql</code> sources match against 
+    addresses contained in a <a href="http://mysql.org/";
+TARGET="Resource Window">MySQL</a> database table. The match field should be the 
+    table name. The MySQL host, user name, password, and database name should 
+    all be configured with the appropriate <a href="config-vars.html"
+TARGET="Resource Window">MYSQL_*</a> variable. The MySQL table format and expected 
+    contents are documented <a href="#MySQL">below</a>.<br>
+    <br>
+    If no flags are specified, the address(es) being tested must exactly match 
+    an entry in the table. Wildcard matching may be done by adding the 
<code>-like</code> 
+    or <code>-rlike</code> flags. <code>-like</code> indicates that MySQL 
<code>LIKE</code> 
+    comparison should be done (i.e. <code>[EMAIL PROTECTED]</code> would match all 
+    users in the <code>my.host.name</code> domain). <code>-rlike</code> indicates 
+    that MySQL regular expression (<code>RLIKE</code>) comparison should be done 
+    (i.e. <code>[EMAIL PROTECTED]</code> would match all users in the 
<code>my.host.name</code> 
+    domain).<br>
+    <br>
 </dl>
-
-The following group of sources may be used only in incoming filter
-files.
-<br><br>
+The following group of sources may be used only in incoming filter files. <br>
+<br>
 
 <dl>
 <dt>
@@ -469,41 +424,23 @@
 <h3>Miscellaneous Notes</h3>
 
 <dl>
-<dt>
-<a name="email_address"><b>Email Addresses</b></a>
-<dd>
-
-In addition to explicit email addresses, you can use expressions
-based on UNIX shell-style wildcard characters anywhere an email
-address is expected.
-
-<br><br>
-
-<strong>NOTE:</strong> Wildcard characters are not recognized in a CDB
-or DBM file.
-
-<br><br>
-
-The special characters are:
-
-<blockquote><pre>
-
-Characters(s)    Description
--------------    -----------
-*                Matches everything.
-?                Matches any single character.
-[seq]            Matches any character in seq.
-[!seq]           Matches any character not in seq.
-
-</blockquote></pre>
-
-In addition, `<code>@=</code>' (a custom rule) will expand to match
-both <code>@</code> and <code>@*.</code>
-
-<br><br>
-
-Here are some common examples:
-<pre><blockquote>
+  <dt> <a name="email_address"><b>Email Addresses</b></a> 
+  <dd> In addition to explicit email addresses, you can use expressions based 
+    on UNIX shell-style wildcard characters anywhere an email address is expected. 
+    <br>
+    <br>
+    <strong>NOTE:</strong> Wildcard characters are not recognized in a CDB or 
+    DBM file. <br>
+    <br>
+    The special characters are: 
+    <blockquote><pre> Characters(s) Description ------------- ----------- * Matches 
+      everything. ? Matches any single character. [seq] Matches any character 
+      in seq. [!seq] Matches any character not in seq. </blockquote></pre>
+    In addition, `<code>@=</code>' (a custom rule) will expand to match both 
<code>@</code> 
+    and <code>@*.</code> <br>
+    <br>
+    Here are some common examples: 
+    <pre><blockquote>
 # match only [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 # match [EMAIL PROTECTED], but not [EMAIL PROTECTED]
@@ -514,114 +451,106 @@
 [EMAIL PROTECTED]
 
 </blockquote></pre>
-<strong>NOTE:</strong> To match the empty envelope sender such as bounce
-messages are sent with, use <b><code><></code></b> as the expression.
-
-<br><br>
-
-<dt>
-<a name="email_file"><b>Email Address Files</b></a>
-<dd>
-
-Email address files are textfiles containing an email address on each
-line.  When using the <code>from-file</code> and <code>to-file</code>
-sources, the textfile is searched sequentially, with the first match
-terminating the search.  Wildcarded email addresses are supported in
-textfiles.
-
-<br><br>
-
-Address files may contain an optional second field on each line that
-specifies an action (<code>ok, drop, bounce, etc.</code>).  If the
-action is specified, it overrides the action given in the filter rule.
-
-<br><br>
-
-<dt>
-<a name="autoflags"><b>Auto- Database Flags</b></a>
-<dd>
-
-If you have lengthy email address textfiles, you might want to
-consider using the much faster hashed databases instead.  The address
-files used by the auto-building hashed database feature are the same
-email address textfiles documented above with the sole exception that
-wildcards are not supported.
-
-<br><br>
-
-The <code>-autocdb</code> and <code>-autodbm</code> arguments are
-intended to ease the use of CDB/DBM lists in TMDA by automatically
-rebuilding the CDB or DBM file as necessary.  This gives you the
-performance advantages of hashed databases without the hassle of
-having to manually maintain them.  With the <code>-auto*</code>
-arguments, TMDA will rebuild the database if it doesn't exist or if
-its timestamp is older than its source file.  If the rebuild fails for
-some reason, TMDA will fall back to matching from the textfile
-instead.
-
-<br><br>
-
-Before you try the CDB version of this feature, make sure you have the
-<a href="http://pilcrow.madison.wi.us/#pycdb"; TARGET="Resource
-Window">python-cdb</a> extension module installed.
-
-<br><br>
-
-<dt>
-<a name="db_file"><b>Database Files</b></a>
-<dd>
-
-CDB and DBM files are hashed databases.  TMDA can look up email
-addresses in these files.  Lookup in these files is much
-faster than in a textfile.  On the other hand, wildcards are not
-supported in database files -- only in textfiles.
-
-<br><br>
-
-In a CDB or DBM, the keys should be the email addresses to match, and
-their corresponding values (or records) should be empty unless you
-want to override the action specified in the filter file.
-
-<br><br>
-
-CDB or DBM files can be created outside of TMDA and merely referenced
-by your filter files (use the <code>*-cdb</code> and
-<code>*-dbm</code> filter rules) or can be automatically created by
-TMDA if you use the <code>-autocdb</code> or <code>-autodbm</code>
-flags and the <code>*-file</code> rules.
-
-<br><br>
-
-If you wish to explore CDB databases, make sure you have the <a
+    <strong>NOTE:</strong> To match the empty envelope sender such as bounce messages 
+    are sent with, use <b><code><></code></b> as the expression. <br>
+    <br>
+  <dt> <a name="email_file"><b>Email Address Files</b></a> 
+  <dd> Email address files are textfiles containing an email address on each line. 
+    When using the <code>from-file</code> and <code>to-file</code> sources, the 
+    textfile is searched sequentially, with the first match terminating the search. 
+    Wildcarded email addresses are supported in textfiles. <br>
+    <br>
+    Address files may contain an optional second field on each line that specifies 
+    an action (<code>ok, drop, bounce, etc.</code>). If the action is specified, 
+    it overrides the action given in the filter rule. <br>
+    <br>
+  <dt> <a name="autoflags"><b>Auto- Database Flags</b></a> 
+  <dd> If you have lengthy email address textfiles, you might want to consider 
+    using the much faster hashed databases instead. The address files used by 
+    the auto-building hashed database feature are the same email address textfiles 
+    documented above with the sole exception that wildcards are not supported. 
+    <br>
+    <br>
+    The <code>-autocdb</code> and <code>-autodbm</code> arguments are intended 
+    to ease the use of CDB/DBM lists in TMDA by automatically rebuilding the CDB 
+    or DBM file as necessary. This gives you the performance advantages of hashed 
+    databases without the hassle of having to manually maintain them. With the 
+    <code>-auto*</code> arguments, TMDA will rebuild the database if it doesn't 
+    exist or if its timestamp is older than its source file. If the rebuild fails 
+    for some reason, TMDA will fall back to matching from the textfile instead. 
+    <br>
+    <br>
+    Before you try the CDB version of this feature, make sure you have the <a 
href="http://pilcrow.madison.wi.us/#pycdb"; TARGET="Resource
+Window">python-cdb</a> extension module installed. <br>
+    <br>
+  <dt> <a name="db_file"><b>Database Files</b></a> 
+  <dd> CDB and DBM files are hashed databases. TMDA can look up email addresses 
+    in these files. Lookup in these files is much faster than in a textfile. On 
+    the other hand, wildcards are not supported in database files -- only in 
textfiles. 
+    <br>
+    <br>
+    In a CDB or DBM, the keys should be the email addresses to match, and their 
+    corresponding values (or records) should be empty unless you want to override 
+    the action specified in the filter file. <br>
+    <br>
+    CDB or DBM files can be created outside of TMDA and merely referenced by your 
+    filter files (use the <code>*-cdb</code> and <code>*-dbm</code> filter rules) 
+    or can be automatically created by TMDA if you use the <code>-autocdb</code> 
+    or <code>-autodbm</code> flags and the <code>*-file</code> rules. <br>
+    <br>
+    If you wish to explore CDB databases, make sure you have the <a
 href="http://pilcrow.madison.wi.us/#pycdb"; TARGET="Resource
-Window">python-cdb</a> extension module installed.
-
-<br><br>
-
-<dt>
-<a name="re_file"><b>Regular Expression Files</b></a>
-<dd>
-
-A regular expression textfile is simply a text file with a regular
-expression on each line.  The file is read sequentially and each
-regular expression is used to attempt a match.  As soon as there is a
-match, the search stops.
-
-<br><br>
-
-Because regular expressions may include spaces, you must surround the
-regular expressions with quotation marks.  You may use either single
-quotes (<code><b>'</b></code>) or double quotes
-(<code><b>"</b></code>) as long as you use the the same one at both
-the beginning and the end.
-
-<br><br>
-
-If you need to match a quote in your regular expression, simply use
-the other style of quotes to surround the expression or escape the
-embedded quote with a backslash (<code><b>\</b></code>).
-<br><br>
-
+Window">python-cdb</a> extension module installed. <br>
+    <br>
+  <dt> <a name="MySQL" id="MySQL"><b>MySQL Tables</b></a> 
+  <dd> MySQL tables used in <code>from-mysql</code> and <code>to-mysql</code> 
+    filter sources should be created with the following SQL: 
+    <p> 
+    <pre>CREATE TABLE &lt;table_name&gt;
+(
+    ADDRESS text NOT NULL,
+    ACTION text NOT NULL,
+    PRIMARY KEY (ADDRESS(80))
+)</pre>
+    The <code>ACTION</code> field in your records may generally be left blank, 
+    but if present, any command in the field will override the action specified 
+    in the filter source. In other words: 
+    <pre>+-------------+--------+
+| ADDRESS     | ACTION |
++-------------+--------+
+| [EMAIL PROTECTED] | bounce |
++-------------+--------+</pre>
+    will cause all mail from yahoo.com to bounce, even if the filter source was: 
+    <pre>from-mysql -like TMDA accept</pre>
+    Make sure that the MySQL user specified in <a 
href="config-vars.html#MYSQL_USER"><code>MYSQL_USER</code></a> 
+    has been <code>GRANT</code>ed sufficient <code>SELECT</code> privileges to 
+    allow access to the table listed in your filter source.<br>
+    <br>
+    The TMDA filter parser will stop on the first matching record found. If you 
+    are using the <code>-like</code> or <code>-rlike</code> options and multiple 
+    table entries match, there is no predicting which record will be used.<br>
+    <br>
+    If you wish to explore MySQL databases, make sure you have the <a
+href="http://sourceforge.net/projects/mysql-python/"; TARGET="Resource
+Window">mysql-python</a> extension module installed. <br>
+    <br></dt>
+    
+  <dd></dt> 
+  <dd></dt> 
+  <dt> <a name="re_file"><b>Regular Expression Files</b></a> 
+  <dd> A regular expression textfile is simply a text file with a regular expression 
+    on each line. The file is read sequentially and each regular expression is 
+    used to attempt a match. As soon as there is a match, the search stops. <br>
+    <br>
+    Because regular expressions may include spaces, you must surround the regular 
+    expressions with quotation marks. You may use either single quotes 
(<code><b>'</b></code>) 
+    or double quotes (<code><b>"</b></code>) as long as you use the the same one 
+    at both the beginning and the end. <br>
+    <br>
+    If you need to match a quote in your regular expression, simply use the other 
+    style of quotes to surround the expression or escape the embedded quote with 
+    a backslash (<code><b>\</b></code>). <br>
+    <br>
 </dl>
 
 

_______________________________________
tmda-cvs mailing list
http://tmda.net/lists/listinfo/tmda-cvs

Reply via email to