Optimistic MX host whitelisting
2007-04-18 by Seth Mos
Hi, I have created a php urlcheck page that checks if the sender IP address is in the same subnet of any of the real MX hosts. This makes the greylisting a bit less intrusive. I have it running for a bit now and it is actively whitelisting real mail servers without delay. Needless to say, dynamic dial up or dsl or cable anything client users fail these test so there is no harm there. One less reason to use greylisting. You can test this by putting the following urlcheck in yourgreylist.conf urlcheck "mxhostcheck" "https://webmail.coltex.nl/spam/mxhostcheck.php?domain=%sf&ip=%i&fuzz=24&delay=180" 5 acl whitelist urlcheck "mxhostcheck" The arguments to this check are as follows. domain, needs to be the sender domain. ip, needs to be the sender ip. fuzz, is a subnetmask to narrow down the match. Pick one. I like 22. delay, a delay in seconds for greylist timeouts. The source of the php page can be viewed here. https://webmail.coltex.nl/spam/mxhostcheck.txt One of the issues with the script currently is that the greylist response is not correctly parsed by milter-greylist-4.0a1 yet. FIXED in milter-greylist-4.0a2! If the match is correct you should see this message in the mail log as well. Milter add: header: X-Greylist: URL check passed, not delayed by milter-greylist-4.0a1 I need some feedback on this. Test the page for your self in your milter-greylist or host the php page localy and work from there. I would very much like that any improvements be communicated back. The PHP code is BSD licensed. I do expect fair use of the url and no more then 5 concurrent connections at the same time. Note that if you want to host the page locally you require the "host" binary to be available on your system. Kind regards, Seth Mos