ws和wss的path参数url解码后发送
http代理connect方法支持host参数自定义 Proxy-Agent修改为nginx
This commit is contained in:
4
http2.go
4
http2.go
@ -372,7 +372,7 @@ func (h *http2Handler) roundTrip(w http.ResponseWriter, r *http.Request) {
|
||||
log.Logf("[http2] %s - %s\n%s", r.RemoteAddr, laddr, string(dump))
|
||||
}
|
||||
|
||||
w.Header().Set("Proxy-Agent", "gost/"+Version)
|
||||
w.Header().Set("Proxy-Agent", ProxyAgent)
|
||||
|
||||
if !Can("tcp", host, h.options.Whitelist, h.options.Blacklist) {
|
||||
log.Logf("[http2] %s - %s : Unauthorized to tcp connect to %s",
|
||||
@ -768,7 +768,7 @@ func (l *h2Listener) handleFunc(w http.ResponseWriter, r *http.Request) {
|
||||
dump, _ := httputil.DumpRequest(r, false)
|
||||
log.Log("[http2]", string(dump))
|
||||
}
|
||||
w.Header().Set("Proxy-Agent", "gost/"+Version)
|
||||
w.Header().Set("Proxy-Agent", ProxyAgent)
|
||||
conn, err := l.upgrade(w, r)
|
||||
if err != nil {
|
||||
log.Logf("[http2] %s - %s %s %s %s: %s",
|
||||
|
Reference in New Issue
Block a user