Improve: HTTP proxy server handler

This commit is contained in:
Dreamacro
2018-08-27 00:06:40 +08:00
parent 2a2e61652f
commit 8ec025b56a
10 changed files with 109 additions and 85 deletions

14
adapters/local/https.go Normal file
View File

@ -0,0 +1,14 @@
package adapters
import (
"net"
"net/http"
)
// NewHTTPS is HTTPAdapter generator
func NewHTTPS(request *http.Request, conn net.Conn) *SocketAdapter {
return &SocketAdapter{
addr: parseHTTPAddr(request),
conn: conn,
}
}