Documentation
¶
Overview ¶
Package relay implements all the SNI relay logic.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// ListenAddr is the address the SNI relay server will listen to.
ListenAddr netip.Addr
// ListenPort is the port the SNI relay expects to receive plain HTTP
// requests to.
ListenPort uint16
// ListenPortTLS is the port the SNI relay expects to receive HTTPS requests
// to.
ListenPortTLS uint16
// ProxyURL is the proxy server address (optional).
ProxyURL *url.URL
// RedirectDomains is a list of wildcards the relay server can reroute.
// If the incoming connection is not from this list, the connection will
// not be accepted.
RedirectDomains []string
}
Config represents the SNI relay server configuration.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server implements all the relay logic, listens for incoming connections and redirects them to the proper server.
func (*Server) AddrPlain ¶
AddrPlain returns the address where the server listens for plain traffic.
Click to show internal directories.
Click to hide internal directories.