Using EDNS Client Subnet to forward the original source IP address to the backend causes several issues:
XPF fixes a few of these issues but still require some parsing and editing of the packet, and does not provide any way to forward arbitrary data.
Using a custom EDNS option would be possible but would still require doing some parsing, with the same issue with regard to compression, TSIG and so on.
The proxy protocol [1] has a very simple design, pre-pending some header to the existing data but leaving it untouched otherwise. The second version is very efficient in term of generation and parsing, and allows for arbitrary data to be passed using the optional TLVs mechanism.
It would be nice if dnsdist could support pre-pending such a header to the UDP or TCP payload before sending it to the backend.
It would be nice to support version 2 of the proxy protocol because it is more flexible. I suspect version 1 is more widely deployed however. We might need to support both.
I suspect we do not care much about what is currently deployed in other products because no-one supports it over UDP, but I might be wrong.
Still for now my humble opinion is that we should only support version 2.
Would be really cool to have that implemented 馃憤
thanks for the reminder!
Most helpful comment
I suspect we do not care much about what is currently deployed in other products because no-one supports it over UDP, but I might be wrong.
Still for now my humble opinion is that we should only support version 2.