gobetween icon indicating copy to clipboard operation
gobetween copied to clipboard

Add basic support for PROXY protocol V2 for TCP backends

Open xabinapal opened this issue 5 years ago • 0 comments

I have made some improvements over the work done in PR #101 to add basic support for PROXY protocol V2 in TCP backends.

At the moment, it can only add the minimum header required to implement this protocol, but it can not set any TLV extension, as the underlying library used to create the header does not support this operation. I'll try to submit a PR to this library and, if it gets merged, I'll add configuration parameters to customize what TLVs are sent (such as SSL options). With this feature in mind, I have also allowed TLS listeners to send PROXY headers to their respective upstreams, so this protocol can be used in TLS termination scenarios.

Finished work

  • [x] Add support for PROXY Protocol V2
  • [x] Allow TLS listeners to use PROXY Protocol in their upstreams
  • [x] Tests for PROXY Protocol V1 and V2, both with IPv4 and IPv6 connections

Pending work

  • [ ] Allow UDP connections to send PROXY Protocol V2
  • [ ] Include extra TLVs in PROXY Protocol V2 headers, such as SSL

xabinapal avatar May 17 '20 15:05 xabinapal