Versions in this module Expand all Collapse all v0 v0.42.0 May 14, 2022 Changes in this version + func HandleUserTCPConnection(pxy Proxy, userConn net.Conn, serverCfg config.ServerCommonConf) + type BaseProxy struct + func (pxy *BaseProxy) Close() + func (pxy *BaseProxy) Context() context.Context + func (pxy *BaseProxy) GetName() string + func (pxy *BaseProxy) GetResourceController() *controller.ResourceController + func (pxy *BaseProxy) GetUsedPortsNum() int + func (pxy *BaseProxy) GetUserInfo() plugin.UserInfo + func (pxy *BaseProxy) GetWorkConnFromPool(src, dst net.Addr) (workConn net.Conn, err error) + type GetWorkConnFn func() (net.Conn, error) + type HTTPProxy struct + func (pxy *HTTPProxy) Close() + func (pxy *HTTPProxy) GetConf() config.ProxyConf + func (pxy *HTTPProxy) GetRealConn(remoteAddr string) (workConn net.Conn, err error) + func (pxy *HTTPProxy) Run() (remoteAddr string, err error) + type HTTPSProxy struct + func (pxy *HTTPSProxy) Close() + func (pxy *HTTPSProxy) GetConf() config.ProxyConf + func (pxy *HTTPSProxy) Run() (remoteAddr string, err error) + type Manager struct + func NewManager() *Manager + func (pm *Manager) Add(name string, pxy Proxy) error + func (pm *Manager) Del(name string) + func (pm *Manager) GetByName(name string) (pxy Proxy, ok bool) + type Proxy interface + Close func() + Context func() context.Context + GetConf func() config.ProxyConf + GetName func() string + GetResourceController func() *controller.ResourceController + GetUsedPortsNum func() int + GetUserInfo func() plugin.UserInfo + GetWorkConnFromPool func(src, dst net.Addr) (workConn net.Conn, err error) + Run func() (remoteAddr string, err error) + func NewProxy(ctx context.Context, userInfo plugin.UserInfo, ...) (pxy Proxy, err error) + type STCPProxy struct + func (pxy *STCPProxy) Close() + func (pxy *STCPProxy) GetConf() config.ProxyConf + func (pxy *STCPProxy) Run() (remoteAddr string, err error) + type SUDPProxy struct + func (pxy *SUDPProxy) Close() + func (pxy *SUDPProxy) GetConf() config.ProxyConf + func (pxy *SUDPProxy) Run() (remoteAddr string, err error) + type TCPMuxProxy struct + func (pxy *TCPMuxProxy) Close() + func (pxy *TCPMuxProxy) GetConf() config.ProxyConf + func (pxy *TCPMuxProxy) Run() (remoteAddr string, err error) + type TCPProxy struct + func (pxy *TCPProxy) Close() + func (pxy *TCPProxy) GetConf() config.ProxyConf + func (pxy *TCPProxy) Run() (remoteAddr string, err error) + type UDPProxy struct + func (pxy *UDPProxy) Close() + func (pxy *UDPProxy) GetConf() config.ProxyConf + func (pxy *UDPProxy) Run() (remoteAddr string, err error) + type XTCPProxy struct + func (pxy *XTCPProxy) Close() + func (pxy *XTCPProxy) GetConf() config.ProxyConf + func (pxy *XTCPProxy) Run() (remoteAddr string, err error)