Documentation
¶
Overview ¶
Package httpproxy implements the HTTP/1.x and HTTP/2 proxy servers for anzu-proxy, including HTTPS CONNECT tunnelling and optional MITM caching.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HTTP2Handler ¶
type HTTP2Handler struct {
// contains filtered or unexported fields
}
HTTP2Handler handles HTTP/2 proxy connections.
func NewHTTP2Handler ¶
func NewHTTP2Handler(conn net.Conn, cfg *config.Config) *HTTP2Handler
NewHTTP2Handler creates a handler for one accepted HTTP/2 connection.
func (*HTTP2Handler) Handle ¶
func (h *HTTP2Handler) Handle()
Handle drives the HTTP/2 server loop for one connection.
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler handles HTTP/1.1 and HTTPS proxy connections on a single client TCP/TLS socket. It supports keep-alive (HTTP/1.1 pipelining of subsequent requests on the same connection).
func NewHandler ¶
NewHandler creates a handler for one accepted connection.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server represents the HTTP/HTTPS proxy server (supports HTTP/1.x and HTTP/2).
func (*Server) Shutdown ¶
Shutdown closes the listener and waits for in-flight handlers to drain, bounded by ctx. Returns ctx.Err() if the deadline expires.