Documentation ¶
Index ¶
Constants ¶
View Source
const ( DefaultStreamReceiveWindow = 8388608 // 8MB DefaultConnReceiveWindow = DefaultStreamReceiveWindow * 5 / 2 // 20MB DefaultMaxIdleTimeout = 30 * time.Second DefaultKeepAlivePeriod = 10 * time.Second )
View Source
const ObfsTypeSalamander = "salamander"
Variables ¶
View Source
var SetCongestionController = func(quicConn quic.Connection, cc string, cwnd int) {
}
Functions ¶
func NewSalamanderConn ¶
func NewSalamanderConn(conn net.PacketConn, password []byte) net.PacketConn
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(options ClientOptions) (*Client, error)
func (*Client) CloseWithError ¶
func (*Client) ListenPacket ¶
type ClientOptions ¶
type ClientOptions struct { Context context.Context Dialer N.Dialer Logger logger.Logger BrutalDebug bool ServerAddress func(ctx context.Context) (*net.UDPAddr, error) HopInterval time.Duration SendBPS uint64 ReceiveBPS uint64 SalamanderPassword string Password string TLSConfig *tls.Config UDPDisabled bool CWND int UdpMTU int }
type SalamanderPacketConn ¶
type SalamanderPacketConn struct { net.PacketConn // contains filtered or unexported fields }
type ServerHandler ¶
type ServerHandler interface { N.TCPConnectionHandler N.UDPConnectionHandler }
type Service ¶
type Service[U comparable] struct { // contains filtered or unexported fields }
func NewService ¶
func NewService[U comparable](options ServiceOptions) (*Service[U], error)
func (*Service[U]) UpdateUsers ¶
type ServiceOptions ¶
type ServiceOptions struct { Context context.Context Logger logger.Logger BrutalDebug bool SendBPS uint64 ReceiveBPS uint64 IgnoreClientBandwidth bool SalamanderPassword string TLSConfig *tls.Config UDPDisabled bool UDPTimeout time.Duration Handler ServerHandler MasqueradeHandler http.Handler CWND int UdpMTU int }
type VectorisedSalamanderPacketConn ¶
type VectorisedSalamanderPacketConn struct { SalamanderPacketConn // contains filtered or unexported fields }
func (*VectorisedSalamanderPacketConn) WriteVectorisedPacket ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.