Giter Club home page Giter Club logo

proxy-protocol's People

Contributors

icgood avatar tommyvn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

gregbanks tommyvn

proxy-protocol's Issues

Non-asyncio socket read

Add read_socket method that can be used by sockets not managed by asyncio. This should also work with gevent sockets.

UDP support?

Thanks very much for providing this library, and for providing examples of both a server and a proxy. It made it very easy to experiment with this!

Do you have any plans to add support for UDP (SOCK_DGRAM) traffic over proxy protocol v2? I've been reading the spec at https://www.haproxy.org/download/1.8/doc/proxy-protocol.txt to try and figure out what things look like on the wire in that case, but I've been unable to find any client or server implementations I could use as an example. It looks like HAProxy may not support UDP, and even NGINX which does support UDP may not support proxy protocol for it. I see signs that some cloud provider load balancers support UDP, but I don't have a setup which allows me to easily test in any of those environments right now.

In particular, it isn't clear to me whether the proxy protocol header is added to every UDP packet or only at the start of a new flow. If it is only added at the start, it isn't clear to me how servers would recover if the packet with this header was lost in transit, or if it arrived out of order.

The closest thing I've found so far is from CloudFlare at https://developers.cloudflare.com/spectrum/proxy-protocol which says for UDP that the proxy protocol v2 header will be prepended to the first packet on a stream, but this doesn't seem to address recovery in the case of packet loss or reordering. That link also describes an alternative "simple proxy protocol" header which is specifically for UDP and puts the header at the beginning of every UDP packet. However, that seems to be a CloudFlare-specific alternative to proxy protocol v2 and I'm not sure that would be available anywhere else.

If you have any more information on support for UDP with proxy protocol v2 in general, that would also be appreciated!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.