Add ALPN header for HTTP proxy according to WebRTC standard
I'm considering adding support for an ALPN header to fulfill the requirements of section 3.4 in draft-ietf-rtcweb-transports, i.e.
The WebRTC endpoint MAY support accessing the Internet through an HTTP proxy. If it does so, it MUST include the "ALPN" header as specified in [RFC7639], and proxy authentication as described in Section 4.3.6 of [RFC7231] and [RFC7235] MUST also be supported.
My idea is that I'll add a property "proxy-alpn" to NiceAgent and a HTTP header with contents
ALPN: <proxy-alpn> in the HTTP CONNECT request. Although not stated explicitly I believe the ALPNs in question for WebRTC will be either
c-webrtc as described in draft-ietf-rtcweb-alpn.
As a default I think it would be correct to use the ALPN header
stun.turn according to rfc7443. However, it might be considered a breaking change to always pass this. Any thoughts on that ?
Regarding the authentication mentioned above I think the spec cited above is a little bit vague since the authentication scheme is extensible. My interpretation though is that we should be ok with the basic authentication that is currently implemented, but if I'm wrong and we would need digest authentication as well then we need to move to HTTP 1.1. This calls for adding a whole new proxy type where also the ALPN is introduced and then the discussion about breaking change becomes moot.
Any input welcome before I just go ahead making a merge request.