v2rayhttp

package
v1.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 8, 2023 License: GPL-2.0 Imports: 25 Imported by: 11

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewClient

func NewClient(ctx context.Context, dialer N.Dialer, serverAddr M.Socksaddr, options option.V2RayHTTPOptions, tlsConfig tls.Config) adapter.V2RayClientTransport

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func (*Client) DialContext

func (c *Client) DialContext(ctx context.Context) (net.Conn, error)

type HTTP2ConnWrapper added in v1.1.3

type HTTP2ConnWrapper struct {
	N.ExtendedConn
	// contains filtered or unexported fields
}

func NewHTTP2Wrapper added in v1.1.3

func NewHTTP2Wrapper(conn net.Conn) *HTTP2ConnWrapper

func (*HTTP2ConnWrapper) CloseWrapper added in v1.1.3

func (w *HTTP2ConnWrapper) CloseWrapper()

func (*HTTP2ConnWrapper) Upstream added in v1.1.3

func (w *HTTP2ConnWrapper) Upstream() any

func (*HTTP2ConnWrapper) Write added in v1.1.3

func (w *HTTP2ConnWrapper) Write(p []byte) (n int, err error)

func (*HTTP2ConnWrapper) WriteBuffer added in v1.1.3

func (w *HTTP2ConnWrapper) WriteBuffer(buffer *buf.Buffer) error

type HTTPConn

type HTTPConn struct {
	// contains filtered or unexported fields
}

func (*HTTPConn) Close

func (c *HTTPConn) Close() error

func (*HTTPConn) LocalAddr

func (c *HTTPConn) LocalAddr() net.Addr

func (*HTTPConn) Read

func (c *HTTPConn) Read(b []byte) (n int, err error)

func (*HTTPConn) RemoteAddr

func (c *HTTPConn) RemoteAddr() net.Addr

func (*HTTPConn) SetDeadline

func (c *HTTPConn) SetDeadline(t time.Time) error

func (*HTTPConn) SetReadDeadline

func (c *HTTPConn) SetReadDeadline(t time.Time) error

func (*HTTPConn) SetWriteDeadline

func (c *HTTPConn) SetWriteDeadline(t time.Time) error

func (*HTTPConn) Write

func (c *HTTPConn) Write(b []byte) (n int, err error)

type Server

type Server struct {
	// contains filtered or unexported fields
}

func NewServer

func NewServer(ctx context.Context, options option.V2RayHTTPOptions, tlsConfig tls.ServerConfig, handler N.TCPConnectionHandler, errorHandler E.Handler) (*Server, error)

func (*Server) Close

func (s *Server) Close() error

func (*Server) Network

func (s *Server) Network() []string

func (*Server) Serve

func (s *Server) Serve(listener net.Listener) error

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(writer http.ResponseWriter, request *http.Request)

func (*Server) ServePacket

func (s *Server) ServePacket(listener net.PacketConn) error

type ServerHTTPConn

type ServerHTTPConn struct {
	HTTPConn
	// contains filtered or unexported fields
}

func (*ServerHTTPConn) Write

func (c *ServerHTTPConn) Write(b []byte) (n int, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL