yuubinsya

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2023 License: MIT Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHandshaker

func NewHandshaker(encrypted bool, password []byte) entity.Handshaker

func NewServer

func NewServer(config Config) *server

Types

type Config

type Config struct {
	Handler             netapi.Handler
	Host                string
	Password            []byte
	TlsConfig           *tls.Config
	Type                Type
	ForceDisableEncrypt bool

	NewListener func(net.Listener) (net.Listener, error)
}

func (Config) String

func (c Config) String() string

type Conn

type Conn struct {
	net.Conn
	// contains filtered or unexported fields
}

func (*Conn) Write

func (c *Conn) Write(b []byte) (int, error)

type PacketConn

type PacketConn struct {
	net.Conn
	// contains filtered or unexported fields
}

func (*PacketConn) ReadFrom

func (c *PacketConn) ReadFrom(payload []byte) (n int, _ net.Addr, err error)

func (*PacketConn) WriteTo

func (c *PacketConn) WriteTo(payload []byte, addr net.Addr) (int, error)

type Type

type Type int
var (
	RAW_TCP   Type = 1
	TLS       Type = 2
	QUIC      Type = 3
	WEBSOCKET Type = 4
	GRPC      Type = 5
	HTTP2     Type = 6
	REALITY   Type = 7
)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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