>"Mark Ennis" <[EMAIL PROTECTED]> writes:
>
>> Would there be a way to do this with outgoing filters:
>>
>> .A local user emails external address [EMAIL PROTECTED] 
>> .The bare message is sent to the recipient.
>> .The address [EMAIL PROTECTED] is auto-added to the whitelist
>>  
>> I know it provides a weaker level of protection that normal, but
>> it's what we need...
>
>Not today.  The 'bare=append' action appends the entire address.
>You could append to a file (using BARE_APPEND, as usual) that isn't
>the users whitelist and, once a day, say, run a script on that file to
>scrape the domain from each address and append '[EMAIL PROTECTED]' to a
>whitelist_domains file, which you would then reference from the
>incoming filter.
>
>I'll add this idea to my list of filter enhancements for TMDA after
>1.0 is released.

It may be possible to do this with the DB_BARE_APPEND variable if you are
appending to a database, but I'm not sure if the [EMAIL PROTECTED] syntax is
still valid.

This is untested, but for MySQL the following might do what you are looking
for, and assumes that you have the needed DB_* variables and a database with
a barewhitelist table containing the address field:

In your config file:
DB_BARE_APPEND = """
  INSERT INTO barewhitelist (address)
  VALUES (
    CONCAT('[EMAIL PROTECTED]',
      RIGHT(%(recipient)s,
        LENGTH(%(recipient)s)-
        INSTR(%(recipient)s,'@')
      )
    )
  )"""
SQL_BAREQHITE = """
  SELECT bw.address
    FROM barewhitelist"""

In your incoming filter file:
  from-sql -wildcards "${SQL_BAREQHITE}" accept

Dave
BEGIN:VCARD
VERSION:2.1
N:Grimberg;David;J;Mr.
FN:David J Grimberg
ORG:Pacific Lutheran University;Computing & Telecommunications
TITLE:Systems Analyst
ROLE:Systems Analyst
TEL;WORK;VOICE:(253) 535-7546
TEL;WORK;FAX:(253) 536-5099
ADR;WORK;ENCODING=QUOTED-PRINTABLE:;Computer Center;Pacific Lutheran University=0D=0AComputing & Telecommunicat=
ions;Tacoma;WA;98447;United States of America
LABEL;WORK;ENCODING=QUOTED-PRINTABLE:Computer Center=0D=0APacific Lutheran University=0D=0AComputing & Telecommun=
ications=0D=0ATacoma, WA 98447=0D=0AUnited States of America
X-WAB-GENDER:2
KEY;X509;ENCODING=BASE64:
    MIICSTCCAbKgAwIBAgIDCwdFMA0GCSqGSIb3DQEBBAUAMGIxCzAJBgNVBAYTAlpB
    MSUwIwYDVQQKExxUaGF3dGUgQ29uc3VsdGluZyAoUHR5KSBMdGQuMSwwKgYDVQQD
    EyNUaGF3dGUgUGVyc29uYWwgRnJlZW1haWwgSXNzdWluZyBDQTAeFw0wMzEwMjkx
    NzUxMjZaFw0wNDEwMjgxNzUxMjZaMEIxHzAdBgNVBAMTFlRoYXd0ZSBGcmVlbWFp
    bCBNZW1iZXIxHzAdBgkqhkiG9w0BCQEWEGdyaW1iZWRqQHBsdS5lZHUwgZ8wDQYJ
    KoZIhvcNAQEBBQADgY0AMIGJAoGBAOniwGPQGo8zKXca1PRimErYv453nLCgpHtr
    9EUU1nOt2J3M/pj5Pak2hB6urDR0H9YCf8b0scBnRh1sqa0qn8b9a3caiiTUhzAO
    lD7iOzy6D5r1kZmJganwsKIooEPuzF1PCcIqyu3K8xnXxONy1Ts8mKe34/CROYJr
    oGVwlzzrAgMBAAGjLTArMBsGA1UdEQQUMBKBEGdyaW1iZWRqQHBsdS5lZHUwDAYD
    VR0TAQH/BAIwADANBgkqhkiG9w0BAQQFAAOBgQB1GRxX8Ng2dJmH5RVBgqxFJH5U
    eAM8/ZlXtR7PCfB1UobFB8HggiQtNWh/Ni6te/soOkKAGLeNHcv7Q63WyS2CLOuc
    4rAVI3GMjAqcx2+pxwPpFc1hkCaGKfgvQiuRjKUIISZ1j4vx6gHxDhNNpVb2+5CL
    6DBkiZabGC9LQuEALw==                                            

EMAIL;PREF;INTERNET:[EMAIL PROTECTED]
EMAIL;INTERNET:[EMAIL PROTECTED]
URL;WORK:http://www.plu.edu/~grimbedj/
FBURL:http://plu.edu/~grimbedj/grimbedj.vfb
REV:20010405T212229Z
END:VCARD
_____________________________________________
tmda-users mailing list ([EMAIL PROTECTED])
http://tmda.net/lists/listinfo/tmda-users

Reply via email to