go-http-tunnel
go-http-tunnel copied to clipboard
Add WebSockets proxy
If you think this is needed vote by adding :+1: thanks!
(Y)
@jenskastensson you have to click the smiley icon on the original comment by mmatczuk
I just tried this with the tcp protocol and it works. Any foreseeable problems with this approach? The other project that has native websockets proxy is frp and it works as well from my tests.
Any idea when the websocket can be supported? I test it just now, still not going through.
Dear dyu, i also tested 'frp', and websocket is working. But is it secured? I don't see any TLS words at its websites
Another vote for WSS support. Would love to use this for remote access to a Home Assistant instance
@mmatczuk httputil.ReverseProxy
was updated in Go 1.12 to support websockets automatically. Theoretically you might be able to close this ticket for free by recompiling against go1.12. See https://github.com/golang/go/issues/26937
I haven't had a chance to test against your project in particular, but I've had success with other code that "just works" after upgrading. I stumbled across both github issues while doing some research, so I thought it might be useful to let you know.
@mmatczuk and @AkeemMcLennon
go version go1.12.4 linux/amd64
2019/04/14 20:33:49 http: proxy error: can't switch protocols using non-Hijacker ResponseWriter type *http2.responseWriter
https://stackoverflow.com/questions/27075478/when-to-use-hijack-in-golang
Over a tcp tunnel, websocket is working with go 1.12.4
Over a tcp tunnel, websocket is working with go 1.12.4
@Grabber can you elaborate on what you did?
@mmatczuk and @AkeemMcLennon
go version go1.12.4 linux/amd64
2019/04/14 20:33:49 http: proxy error: can't switch protocols using non-Hijacker ResponseWriter type *http2.responseWriter
https://stackoverflow.com/questions/27075478/when-to-use-hijack-in-golang
I'd still be interested in this feature.... Can anybody out there give me a hint on how that could be implemented? Or point me to a source to "copy"?
fyi #32763