A load balancer or a TLS-terminating device connects to the node under its own name, and the client’s real address is lost. The mechanism restores it: the node expects the PROXY header first and takes the address and port from it. It detects the version by itself, both of them.
The trio of lines is the same for both kinds of entry point β the mail listener and the Transmissions API entry point: use-inbound-proxy enables it, inbound-proxy-timeout limits the wait (five seconds by default, then disconnect), log-inbound-proxy shows what arrived.
π΄ Without this mechanism everything that looks at the source address collapses. Matching of the <source> block β and with it the right to send through the node, limits and processing of control headers β is computed from the client’s address. Having lost it, the node sees the same load balancer address for all submitters and stops telling them apart.
π΄ And right there is the opposite danger: the address becomes the client’s claim. Behind a load balancer in a closed network this is safe. On an entry point reachable from anywhere it is not: whoever connects can declare any address and get whatever rights that address has.
π If one appears, it must be enabled at the same time as the balancer β the line without a load balancer closes every connection β and the entry point must then be closed to everyone except the load balancer itself. Otherwise the right to submit goes to anyone who claims our address.
The mechanism has no values of its own β it is enabled by three lines, the same for both kinds of entry point:
| What | Line | Default |
|---|---|---|
| enable acceptance | use-inbound-proxy | off |
| how long to wait | inbound-proxy-timeout | 5 seconds |
| show what was received | log-inbound-proxy | off |
# the entry point is closed to everyone except the load balancer β otherwise any address can be claimed <smtp-listener 10.0.0.0/24:2525> use-inbound-proxy yes inbound-proxy-timeout 1s </smtp-listener>
what people get wrong and how it ends2 mistakesβΆ
our experience
Β§ 3.3.17.16
2 relations
nc -zv NODE 2525
3 articles
βWho is allowed to submit mail and for whom to accept itOut of the box, the node accepts submission only from the machine itself; two different questions β βwho can send through usβ and βfor whose addresses we accept mailβ β are answered by different directives.βHeaders the sender uses to control deliverySix control headers let the submitting side choose a stream, tag a message with a job, set signing options and the key, the envelope identifier and the schedule; each is allowed separately and per source.βWhat the submission bindings needWhat must be in place on the submitting side for the bindings to work: a library, permissions and group membership.