Is it possible to have multiple pickup events?
Is it possible to have multiple pickup events?
I've been using SNIMTA for a few months (and I love it, thank you), but I'm now wanting to add the "attachment" filter as well using the KillSoBig.vbs pickup event. My problem is, I don't see anyway to run two pickup events at the same time. Am I right? I tried to make a batch file that called both the SNIMTA.exe and the KillSoBig.vbs, but it looks like neither work when I do that.
Any ideas? Can I have two pickup events in MailEnable Standard?
Thanks.
Yip
Any ideas? Can I have two pickup events in MailEnable Standard?
Thanks.
Yip
Also found a thread on this issue here....
http://forum.mailenable.com/viewtopic.php?t=1416
...but still don't have a solution.
Anyone?
Yip
http://forum.mailenable.com/viewtopic.php?t=1416
...but still don't have a solution.
Anyone?
Yip
It certainly looks like you can only have one pickup event, though (according to the aforementioned thread) you can call multiple events via a batch file. I'm still not able to get this to work, however.
Support -- any ideas? I can't be the ONLY person wanting to call two different pickup events, can I?
Thx.
Yip
Support -- any ideas? I can't be the ONLY person wanting to call two different pickup events, can I?
Thx.
Yip
Multiple events with batch file
Yep, you're the ONLY one!
Seriously, the MTA calls your pickup event with passing it a single parameter (the name of the mail file) so what you need to do is have your batch file pick up that command prompt parameter, then refeed it into your other calls within the batch.
Hope this helps, I know it was the one thing that bit me several times. I setup my batch file, but each individual call inside didn't know what mail file to deal with, only the batch file got that parameter, and I was doing nothing with it.
Lantz
Seriously, the MTA calls your pickup event with passing it a single parameter (the name of the mail file) so what you need to do is have your batch file pick up that command prompt parameter, then refeed it into your other calls within the batch.
Hope this helps, I know it was the one thing that bit me several times. I setup my batch file, but each individual call inside didn't know what mail file to deal with, only the batch file got that parameter, and I was doing nothing with it.
Lantz
The MTA passes two parameters to scripts or programs, namely the message/command filename (same name, different folders) and the connector ID, e.g., SMTP, so that your script/program knows where to find the file pair. (Your script/program retrives the path from the registry.) One way to call multiple filters is to set the MTA pick up event to a batch file that in turn calls the programs.
1) Using Notepad, create FILTERS.CMD and save it in ME's \bin folder.
===FILTERS.CMD=====================
cscript //T:20 "C:\Program Files\Mail Enable\Bin\killsobig.vbs" %1 %2
C:\Program Files\Mail Enable\SNIMTA\SNIMTA.exe %1 %2
===================================
2) In the MTA properties, check Enable pickup event and type "C:\Program Files\Mail Enable\Bin\filters.cmd" (with quotes) in the Program to execute on mail file: text box.
3) Click Ok, then right-click MTA and first Stop and then Start the MTA service.
The script/programs in this example are those that you mentioned, but any filter could be substituted or added in this batch file. When you change FILTERS.CMD you do not need to stop and start the MTA.
One caveat for your multiple script/program environment. The order of scripts/programs could be an important factor. If a previous script/program has deleted files, the second will get a filename that no longer exists. This could leave leave your script in a state of confusion or something worse. If you add a script of your own that follows another, be sure that it tests whether the files exist before operating on them.
1) Using Notepad, create FILTERS.CMD and save it in ME's \bin folder.
===FILTERS.CMD=====================
cscript //T:20 "C:\Program Files\Mail Enable\Bin\killsobig.vbs" %1 %2
C:\Program Files\Mail Enable\SNIMTA\SNIMTA.exe %1 %2
===================================
2) In the MTA properties, check Enable pickup event and type "C:\Program Files\Mail Enable\Bin\filters.cmd" (with quotes) in the Program to execute on mail file: text box.
3) Click Ok, then right-click MTA and first Stop and then Start the MTA service.
The script/programs in this example are those that you mentioned, but any filter could be substituted or added in this batch file. When you change FILTERS.CMD you do not need to stop and start the MTA.
One caveat for your multiple script/program environment. The order of scripts/programs could be an important factor. If a previous script/program has deleted files, the second will get a filename that no longer exists. This could leave leave your script in a state of confusion or something worse. If you add a script of your own that follows another, be sure that it tests whether the files exist before operating on them.
Last edited by puzzled on Tue Sep 02, 2003 8:31 pm, edited 2 times in total.
Works for me!
Thanks puzzled!!
This works great for me. I was trying to do it on my own with VBS, but this simple batch file works perfectly.
I would recommend ME staff post this in the third party download section.
With SNIMTA, KillSoBig, and PandaCL running together, I have total protection!!
This works great for me. I was trying to do it on my own with VBS, but this simple batch file works perfectly.
I would recommend ME staff post this in the third party download section.
With SNIMTA, KillSoBig, and PandaCL running together, I have total protection!!
one quick note
is that not being a coder of any sorts, i was kinda following advice to the letter....so when you said...
===FILTERS.CMD=====================
cscript //T:20 "C:\Program Files\Mail Enable\Bin\killsobig.vbs" %1 %2
C:\Program Files\Mail Enable\SNIMTA\SNIMTA.exe %1 %2
===================================
thats exactly what i put in the filters.cmd file
I kinda thought the equals signs were like commented out or something however when i looked at cpu i had 100% usage and 20 or more cmd.exe's running...
It took me a little while to figure it out and lo and behold its now working, just thought i'd post up in case any body else done the same thing as me..
thanks again guys...
===FILTERS.CMD=====================
cscript //T:20 "C:\Program Files\Mail Enable\Bin\killsobig.vbs" %1 %2
C:\Program Files\Mail Enable\SNIMTA\SNIMTA.exe %1 %2
===================================
thats exactly what i put in the filters.cmd file
I kinda thought the equals signs were like commented out or something however when i looked at cpu i had 100% usage and 20 or more cmd.exe's running...
It took me a little while to figure it out and lo and behold its now working, just thought i'd post up in case any body else done the same thing as me..
thanks again guys...
Still having problems.
I have a filters.cmd set up and it runs a scripts that copies all mail into another mailbox and runs SNIMTA. However, it runs the script fine but it doesn't appear to be running SNIMTA. This is what I have in my batch file:
cscript.exe //T:20 "F:\Program Files\Mail Enable\Bin\copymail.vbs" %1 %2
"F:\Program Files\Mail Enable\SNIMTA\SNIMTA.EXE" %1 %2
Anyone have any ideas?
cscript.exe //T:20 "F:\Program Files\Mail Enable\Bin\copymail.vbs" %1 %2
"F:\Program Files\Mail Enable\SNIMTA\SNIMTA.EXE" %1 %2
Anyone have any ideas?
-
- Posts: 77
- Joined: Wed Feb 25, 2004 12:40 am
- Location: United Kingdom
Multiple SNIMTA MTA events. One nice, one mean.
Just curious if anyone has tried this.
I have tried the FILTERS.CMD as outlined above to run two separate SNIMTA events, one from the normal SNIMTA directory, one from another called SNIMTAKILL. In the first, I use the large list of words and phrases in the bannedphrases.txt file to tag all suspect spam (SNIMTA.CFG WUSSMODE=YES) and pass the tagged mail on to clients.
In the SNIMTAKILL directory, I use only really offensive words and phrases in the bannedphrases.txt file and changed the SNIMTA.CFG to delete mail (WUSSMODE=NO).
Only the SNIMTA one works, regardless of whether it is before or after the SNIMTAKILL one. Any ideas why only the one event will process?
(I have run MEMTA -DEBUG). The MTA shows that they BOTH run on the offending test mail, but I have confirmed that only the SNIMTA one actually does anything. There are NO log entries in the stats under the SNIMTAKILL copy.
Thoughts? Suggestions?
I have tried the FILTERS.CMD as outlined above to run two separate SNIMTA events, one from the normal SNIMTA directory, one from another called SNIMTAKILL. In the first, I use the large list of words and phrases in the bannedphrases.txt file to tag all suspect spam (SNIMTA.CFG WUSSMODE=YES) and pass the tagged mail on to clients.
In the SNIMTAKILL directory, I use only really offensive words and phrases in the bannedphrases.txt file and changed the SNIMTA.CFG to delete mail (WUSSMODE=NO).
Only the SNIMTA one works, regardless of whether it is before or after the SNIMTAKILL one. Any ideas why only the one event will process?
(I have run MEMTA -DEBUG). The MTA shows that they BOTH run on the offending test mail, but I have confirmed that only the SNIMTA one actually does anything. There are NO log entries in the stats under the SNIMTAKILL copy.
Thoughts? Suggestions?