FutureQuest, Inc. FutureQuest, Inc. FutureQuest, Inc.

FutureQuest, Inc.
Go Back   FutureQuest Community > General Site Owner Support (All may read/respond) > Email & Mailing List Management
User Name
Password  Lost PW

Reply
 
Thread Tools Search this Thread Display Modes
Old 04-03-2002, 07:37 PM   Postid: 65063
kitchin
Site Owner

Forum Notability:
1163 pts: A True Crowd-pleaser!
[Post Feedback]
 
Join Date: Jan 2001
Location: Virginia
Posts: 2,992
EFM: forward instead of bounce/blackhole

I think there is an open question of how to use EFM to forward bad email instead of blackholing or bouncing it. Here is a way of doing something close.

You can forward the good mail, instead of the bad mail, using condredirect. Your bad mail goes to the mailbox to which it was addressed.

Not ideal, but I'll describe how to do it, and then in a follow-up post suggest an idea for getting bad mail to forward.
Code:
1. To avoid email loops, you could use this POP setup with
a single account:
  catch-all@domain.tld -- your catch-all email address
  good-mail@domain.tld -- place for good messages that pass the filter
Do not use Global Filters in this setup, since that would be a loop.
  
2. Use EFM to make a filter that "blackholes" the bad mail
that you really want to save to examine.
Say the filter is called:
  /big/dom/xdomain/emailfilter/emailfilter_1.py

3. In your CNC, create a Simple Filter for your catch-all@domain.tld.
Normally for EFM you would use:
  /big/dom/xdomain/emailfilter/emailfilter_1.py
Instead use:
  condredirect good-mail@domain.tld /big/dom/xdomain/emailfilter/emailfilter_1.py
The bad mail will stay in catch-all@domain.tld for you to examine.
The good mail will go to good-mail@domain.tld.

You can also use "bounce" actions in the same EFM filter. Because of an undocumented behavior of condredirect, "bounce" instructions will pass through condredirect unchanged. Here is the undocumented info:
http://www.aota.net/forums/showthrea...5056#post65056

How it works:

EFM can have 3 exit values (right?):
Code:
1. EFM --> exits 0-good --> condredirect fwds msg to good-mail --> exits 99-stop

2. EFM --> exits 99-blackhole --> condredirect does nothing --> exits 0-deliver

3. EFM --> exits 100-bounce --> condredirect does nothing --> exits 100-bounce
kitchin is offline   Reply With Quote
Old 04-03-2002, 08:07 PM   Postid: 65065
kitchin
Site Owner

Forum Notability:
1163 pts: A True Crowd-pleaser!
[Post Feedback]
 
Join Date: Jan 2001
Location: Virginia
Posts: 2,992
To get an EFM filter to forward bad mail and ignore good mail, a new version of FQ's shell command "except" would be handy. Say there were a program called
Code:
NAME
  exceptstop - switch the exit code of a program with 99

SYNOPSIS
  exceptstop program [ arg ...  ]

DESCRIPTION
  exceptstop runs program with the given arguments.

  If program exits  0, exceptstop exits 99.
  If program exits 100, exceptstop exits 100;
  If program exits 111, exceptstop exits 111.
  If program exits anything  else, exceptstop exits 0.

SEE ALSO
  except(1), condredirect(1)
Then the CNC Simple Filter
Code:
condredirect bad@domain.tld exceptstop /big/dom/x/emailfilter/emailfilter_1.py
(I'm shortening xdomain to x so it will fit here on one nice line.)
would filter "blackholed" mail to bad@domain.tld and let good mail go to its intended email box.


Might as well write it out (it's confusing to me anyway):
Code:
1. EFM --> exits 0-good --> exceptstop --> exits 99-stop
   --> condredirect does nothing --> exits 0-deliver

2. EFM --> exits 99-blackhole --> exceptstop --> exits 0-good
   --> condredirect fwds msg to bad@ --> exits 99-stop

3. EFM --> exits 100-bounce --> exceptstop --> exits 100-bounce
   --> condredirect does nothing --> exits 100-bounce
Does anyone know how to write something like "exceptstop"?


(A simpler program that just changes 100 to 99 could be used in conjunction with the existing "except" command. It would change bounce actions into forwards, which would be more confusing.)

When I say forward I mean redirect. Errr.
kitchin is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 visitors)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 08:18 AM.


Running on vBulletin®
Copyright © 2000 - 2013, Jelsoft Enterprises Ltd.
Hosted & Administrated by FutureQuest, Inc.
Images & content copyright © 1998-2013 FutureQuest, Inc.
FutureQuest, Inc.