ninenines / gun

HTTP/1.1, HTTP/2, Websocket client (and more) for Erlang/OTP.
ISC License
891 stars 232 forks source link

Document gotchas using Gun from multiple entities using HTTP/2 #333

Open essen opened 4 months ago

essen commented 4 months ago

https://datatracker.ietf.org/doc/html/rfc7541#section-7.1

If Gun is used to have a single connection to an origin, serving requests from mutually distrustful entities (for example if Gun is used to implement a proxy merging multiple connections into one), then the current implementation of Gun is not as secure as it could be as attacks on the connection's dynamic state are possible (though fairly difficult).

The same will be true in the initial HTTP/3 release.

In proxy cases part of the solution will require some modifications in Cowboy as well, to propagate the never indexed bits.

This is something that would be nice to fix eventually but for the time being the appropriate explanations and disclaimer will do.