wie...@porcupine.org (Wietse Venema) writes: > Dave T?ht: >> d...@teklibre.org (Dave T?ht) writes: >> >> One unanswered question from this series of emails: >> >> >> Dave Taht: >> > >> > Would you take a patch that would let a crazed administrator disable >> > *sending* mail on different protocols? >> > >> > The simplest version would implement something like: >> > >> > smtp_try_sendprotocol: all, ipv4, ipv6 >> > >> > A more complex version would let you specify the protocols your >> > configuration would try. >> > >> > smtp_try_sendprotocol_my_networks: all, ipv4, ipv6 >> > smtp_try_sendprotocol_my_relays: all, ipv4, ipv6 >> > >> >> Maybe there's a way to do this already... > > Postfix sorts the remote SMTP server IP addresses by MX preference, > which are numbers in the range 0..32767. The next step is to avoid > backup MX loops: for this, the Postfix SMTP client must remove all > MX addresses that have the same of worse preference than Postfix's > own IP address. > > To give preference for IPvX over IPvY, it is sufficient to tweak > those preference numbers. For example, one could multiply the MX > preferences by 2, then add 1 if the address belongs to the less > preferred protocol. With this, Postfix can still correctly avoid > backup MX loops (the address elimination becomes a little trickier, > though).
In my case, the mail servers involved are generally behind ipv4 NAT and thus will not have a correct reverse lookup. If they try to connect at all with other ipv4 servers on the net, some will no doubt be rejected (rightly) due to anti-spam measures. They need to iterate through the ipv6 enabled components of the mx list, then fall back to the dual homed smart host(s). They do (all but one that I'm trying to get fixed today (and coping with reverse DNS is a major hassle with ipv6)) have a valid reverse for ipv6 addresses. You make a good point about the possibility of invoking a mx loop if filtering of mx records and smart hosts is combined. I will try to wrap my head around it and the code this weekend. -- Dave Taht http://the-edge.blogspot.com