#2997·Rocket

Proxy protocol support?

Author: kanashimiaCreated May 18, 2026Updated May 18, 2026
Labelsrequest

What's missing?

It seems Rocket supports X-Forwarded-For header and alike, but not PROXY Protocol. Considering Rocket basically requires a proxy before it, that would be nice to have feature.

explanation: https://www.haproxy.com/blog/use-the-proxy-protocol-to-preserve-a-clients-ip-address spec: https://www.haproxy.org/download/3.4/doc/proxy-protocol.txt

What do you think?

Ideal Solution

No response

Why can't this be implemented outside of Rocket?

It relies on the TCP layer communication, how possible to implement that outside? But also considering that Rocket already has handling of X-Forwarded-For headers, and PROXY Protocol is a more low-level feature, it would make sense to have it here?

Are there workarounds usable today?

No response

Alternative Solutions

No response

Additional Context

It is not something I stronglyyyyy need, but would be nice. There are crates for it, but I'm not familiar with Rocket internals, shouldn't be hard to implement anyways manually. Also there are v1 and v2 versions of the protocol, this is a request about v2 version here.

System Checks

  • I do not believe that this feature can or should be implemented outside of Rocket.
  • I was unable to find a previous request for this feature.