<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>
Hi Jules,<BR>
&nbsp;<BR>
I considered that transport maps in postfix was not the general case and was not suggesting that it is somthing that should be worked into the product, not unless it was specifically warranted. I will look into the CustomFunctions as i do know a bit of&nbsp;Perl and sorry you did answer the question initially, just my eyes not working so good sitting at a screen all day...Just as a quick question though, does and ammendment to a ruleset require a restart of MailScanner?<BR>
&nbsp;<BR>
Regards<BR>
&nbsp;<BR>
Caza<BR><BR>&gt; Date: Tue, 2 Sep 2008 09:00:33 +0100<BR>&gt; From: MailScanner@ecs.soton.ac.uk<BR>&gt; To: mailscanner@lists.mailscanner.info<BR>&gt; Subject: Re: Rules with IP addresses<BR>&gt; <BR>&gt; <BR>&gt; <BR>&gt; Caza Henha wrote:<BR>&gt; &gt; Hi Jules,<BR>&gt; &gt; <BR>&gt; &gt; Thanks for the answer, I presumed that would be the case, but I was <BR>&gt; &gt; thinking that as our postfix configuration has transport maps it does <BR>&gt; &gt; actually know before sending the mail to our application server what <BR>&gt; &gt; the destination IP address is.<BR>&gt; But that is not the general case, and I'm certainly not going to start <BR>&gt; processing entire Postfix configurations in an attempt to work it out. <BR>&gt; Sorry :(<BR>&gt; &gt; Does this mean then that something like the following would be necessary:<BR>&gt; &gt; <BR>&gt; &gt; To: support@example.com &lt;mailto:support@example.com&gt; store <BR>&gt; &gt; //Ticketing server<BR>&gt; &gt; To: issues@example.com &lt;mailto:issues@example.com&gt; store <BR>&gt; &gt; //Ticketing server<BR>&gt; &gt; ....<BR>&gt; &gt; To: application1@example.com &lt;mailto:application1@example.com&gt; <BR>&gt; &gt; delete //App Server 1<BR>&gt; &gt; To: application2@example.com &lt;mailto:application2@example.com&gt; <BR>&gt; &gt; store //App Server 2<BR>&gt; &gt; ...<BR>&gt; &gt; To: user@example.com &lt;mailto:user@example.com&gt; delete <BR>&gt; &gt; //Exchange server<BR>&gt; &gt; To: user@example.com &lt;mailto:user@example.com&gt; delete <BR>&gt; &gt; //Exchange server<BR>&gt; &gt; .....<BR>&gt; &gt; FromOrTo: default deliver //Public Mail server<BR>&gt; &gt; <BR>&gt; &gt; Bearing in mind that there are 1000s of different email address <BR>&gt; &gt; permutations going to the app servers (writing a script to create the <BR>&gt; &gt; rules is easy) would there be any performance problems with <BR>&gt; &gt; Mailscanner reading these files?<BR>&gt; I wouldn't advise more than 1000 or so rules in a ruleset file. For <BR>&gt; anything bigger than that use a Custom Function. I suspect yours could <BR>&gt; be written as a Custom Function quite easily. Take a look in <BR>&gt; /usr/lib/MailScanner/MailScanner/CustomFunctions/*.pm and you'll see how <BR>&gt; to do it. Not hard if you know a bit of Perl.<BR>&gt; &gt; Also when using an IP address in the "From" could you direct me to <BR>&gt; &gt; information from the question below:<BR>&gt; &gt; <BR>&gt; &gt; &gt; &gt; Consequently I have noticed a number of examples have IP addresses in<BR>&gt; &gt; &gt; &gt; the From section of the rules and I was just wondering where this IP<BR>&gt; &gt; &gt; &gt; address was coming from and what it can actually be as I cannot seem<BR>&gt; &gt; &gt; &gt; to find any documentation on it. For example is this IP address (or<BR>&gt; &gt; &gt; &gt; the RegEx of one) the connecting smtp server (or any smtp server that<BR>&gt; &gt; &gt; &gt; the mail has passed through), client address, MX address of the<BR>&gt; &gt; &gt; &gt; sending domain etc or any combination of all the previous?<BR>&gt; I answered that in my previous mail, I believe. Here it is again <BR>&gt; copy-and-pasted from the quote below:<BR>&gt; <BR>&gt; &gt; It is the IP address of the machine that was the client end of the SMTP<BR>&gt; &gt; connection to the server. So in the case of a customer-facing SMTP<BR>&gt; &gt; server, it will be the customer's client IP address. In the case of an<BR>&gt; &gt; MX it would be the IP address of the SMTP server talking to you.<BR>&gt; &gt; <BR>&gt; &gt; &gt; Date: Mon, 1 Sep 2008 12:22:45 +0100<BR>&gt; &gt; &gt; From: MailScanner@ecs.soton.ac.uk<BR>&gt; &gt; &gt; To: mailscanner@lists.mailscanner.info<BR>&gt; &gt; &gt; Subject: Re: Rules with IP addresses<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; Caza Henha wrote:<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; Hi,<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; I have recently installed Mailscanner with Postfix and MailWatch and<BR>&gt; &gt; &gt; &gt; it seems over the last week the system is running great, however I am<BR>&gt; &gt; &gt; &gt; now getting requests to tweak the default rules that I have from<BR>&gt; &gt; &gt; &gt; various users in different departments. I have been trying to delve<BR>&gt; &gt; &gt; &gt; into the knitty gritty of the rules and understand the principles and<BR>&gt; &gt; &gt; &gt; they do not seem very complicated and when looking at some <BR>&gt; &gt; examples on<BR>&gt; &gt; &gt; &gt; the Wiki things shouldn't be to difficult.<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; Consequently I have noticed a number of examples have IP addresses in<BR>&gt; &gt; &gt; &gt; the From section of the rules and I was just wondering where this IP<BR>&gt; &gt; &gt; &gt; address was coming from and what it can actually be as I cannot seem<BR>&gt; &gt; &gt; &gt; to find any documentation on it. For example is this IP address (or<BR>&gt; &gt; &gt; &gt; the RegEx of one) the connecting smtp server (or any smtp server that<BR>&gt; &gt; &gt; &gt; the mail has passed through), client address, MX address of the<BR>&gt; &gt; &gt; &gt; sending domain etc or any combination of all the previous?<BR>&gt; &gt; &gt; It is the IP address of the machine that was the client end of the SMTP<BR>&gt; &gt; &gt; connection to the server. So in the case of a customer-facing SMTP<BR>&gt; &gt; &gt; server, it will be the customer's client IP address. In the case of an<BR>&gt; &gt; &gt; MX it would be the IP address of the SMTP server talking to you.<BR>&gt; &gt; &gt; &gt;<BR>&gt; &gt; &gt; &gt; Also can this be used in a "To" configuration,<BR>&gt; &gt; &gt; No. Due to the way mail delivery works, you don't know the IP <BR>&gt; &gt; address of<BR>&gt; &gt; &gt; the destination until you have already started sending the message.<BR>&gt; &gt; &gt; Can't be done.<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; Jules<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; --<BR>&gt; &gt; &gt; Julian Field MEng CITP CEng<BR>&gt; &gt; &gt; www.MailScanner.info<BR>&gt; &gt; &gt; Buy the MailScanner book at www.MailScanner.info/store<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; Need help customising MailScanner?<BR>&gt; &gt; &gt; Contact me!<BR>&gt; &gt; &gt; Need help fixing or optimising your systems?<BR>&gt; &gt; &gt; Contact me!<BR>&gt; &gt; &gt; Need help getting you started solving new requirements from your boss?<BR>&gt; &gt; &gt; Contact me!<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; --<BR>&gt; &gt; &gt; This message has been scanned for viruses and<BR>&gt; &gt; &gt; dangerous content by MailScanner, and is<BR>&gt; &gt; &gt; believed to be clean.<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; --<BR>&gt; &gt; &gt; MailScanner mailing list<BR>&gt; &gt; &gt; mailscanner@lists.mailscanner.info<BR>&gt; &gt; &gt; http://lists.mailscanner.info/mailman/listinfo/mailscanner<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; Before posting, read http://wiki.mailscanner.info/posting<BR>&gt; &gt; &gt;<BR>&gt; &gt; &gt; Support MailScanner development - buy the book off the website!<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; &gt; ------------------------------------------------------------------------<BR>&gt; &gt; Try Facebook in Windows Live Messenger! Try it Now! <BR>&gt; &gt; &lt;http://clk.atdmt.com/UKM/go/111354030/direct/01/&gt;<BR>&gt; <BR>&gt; Jules<BR>&gt; <BR>&gt; -- <BR>&gt; Julian Field MEng CITP CEng<BR>&gt; www.MailScanner.info<BR>&gt; Buy the MailScanner book at www.MailScanner.info/store<BR>&gt; <BR>&gt; Need help customising MailScanner?<BR>&gt; Contact me!<BR>&gt; Need help fixing or optimising your systems?<BR>&gt; Contact me!<BR>&gt; Need help getting you started solving new requirements from your boss?<BR>&gt; Contact me!<BR>&gt; <BR>&gt; PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654<BR>&gt; <BR>&gt; <BR>&gt; -- <BR>&gt; This message has been scanned for viruses and<BR>&gt; dangerous content by MailScanner, and is<BR>&gt; believed to be clean.<BR>&gt; <BR>&gt; -- <BR>&gt; MailScanner mailing list<BR>&gt; mailscanner@lists.mailscanner.info<BR>&gt; http://lists.mailscanner.info/mailman/listinfo/mailscanner<BR>&gt; <BR>&gt; Before posting, read http://wiki.mailscanner.info/posting<BR>&gt; <BR>&gt; Support MailScanner development - buy the book off the website! <BR><BR><br /><hr />Try Facebook in Windows Live Messenger! <a href='http://clk.atdmt.com/UKM/go/111354030/direct/01/' target='_new'>Try it Now!</a></body>
</html>