Custom tx.notes.outbound_helo not working
analogic opened this issue · comments
It took me a while to find this bug. Outbound IP works fine, but HELO/EHLO does not
There is this code:
Lines 296 to 303 in f4cc2a6
But as bind_helo is already set here
https://github.com/haraka/haraka-net-utils/blob/577087b08c770919c2477378162f9971ab454295/lib/HarakaMx.js#L28-L32
there is no way to set up a custom EHLO.
Thinking out loud: I may not have completely fixed #2911 yet. If mx.bind
is set, it's probably necessary in try_delivery
to check the IP family of the mx.bind
value and the IP family of mx.exchange
. If they aren't the same, log a skip message and try the next MX.
- yes, bind_helo can be set in get_mx, but if you need to set helo and/or outbound ip and do not want to duplicate the default workflow for finding mx, then notes are the way to go.
- Setting custom outbound ip and setting helo accordingly sounds to me like the right thing to do if ip-domain is paired (actually this feature is not from my head).
- I set these two things based on source (e.g. user account) not destination - it's been too long since I implemented it so I can't tell you the right reason, but I think it might have something to do with dedicated outbound IP per customer (domain).
(I admit it's kind of against recommendation, but hey, it works and I'm also testing it automatically, so no harm if it stops working and I have to go the "get_mx" way)
#3363 Fix this, thanks!