Help us shape the future of Go! Take the 2026 Go Developer Survey

shadowsocks

package
v1.14.3 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: GPL-2.0 Imports: 31 Imported by: 10

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewError deprecated

func NewError(logger logger.ContextLogger, ctx context.Context, err error)

Deprecated: remove

func NewInbound

func NewInbound(ctx context.Context, router adapter.Router, logger log.ContextLogger, tag string, options option.ShadowsocksInboundOptions) (adapter.Inbound, error)

func RegisterInbound

func RegisterInbound(registry *inbound.Registry)

func RegisterOutbound

func RegisterOutbound(registry *outbound.Registry)

Types

type Inbound

type Inbound struct {
	inbound.Adapter
	// contains filtered or unexported fields
}

func (*Inbound) NewConnection added in v1.14.0

func (h *Inbound) NewConnection(ctx context.Context, conn net.Conn, metadata adapter.InboundContext, onClose N.CloseHandlerFunc)

func (*Inbound) NewError

func (h *Inbound) NewError(ctx context.Context, err error)

func (*Inbound) NewPacket added in v1.14.0

func (h *Inbound) NewPacket(buffer *buf.Buffer, source M.Socksaddr)

func (*Inbound) Start

func (h *Inbound) Start(stage adapter.StartStage, scope *adapter.Scope) error

type MultiInbound

type MultiInbound struct {
	inbound.Adapter
	// contains filtered or unexported fields
}

func (*MultiInbound) NewConnection added in v1.14.0

func (h *MultiInbound) NewConnection(ctx context.Context, conn net.Conn, metadata adapter.InboundContext, onClose N.CloseHandlerFunc)

func (*MultiInbound) NewError

func (h *MultiInbound) NewError(ctx context.Context, err error)

func (*MultiInbound) NewPacket added in v1.14.0

func (h *MultiInbound) NewPacket(buffer *buf.Buffer, source M.Socksaddr)

func (*MultiInbound) SetTracker added in v1.12.0

func (h *MultiInbound) SetTracker(tracker adapter.SSMTracker)

func (*MultiInbound) Start

func (h *MultiInbound) Start(stage adapter.StartStage, scope *adapter.Scope) error

func (*MultiInbound) UpdateUsers added in v1.12.0

func (h *MultiInbound) UpdateUsers(users []string, uPSKs []string) error

type Outbound

type Outbound struct {
	outbound.Adapter
	// contains filtered or unexported fields
}

func (*Outbound) CloseIdleConnections added in v1.14.3

func (h *Outbound) CloseIdleConnections()

func (*Outbound) DialContext

func (h *Outbound) DialContext(ctx context.Context, network string, destination M.Socksaddr) (net.Conn, error)

func (*Outbound) InterfaceUpdated

func (h *Outbound) InterfaceUpdated(ctx context.Context)

func (*Outbound) ListenPacket

func (h *Outbound) ListenPacket(ctx context.Context, destination M.Socksaddr) (net.PacketConn, error)

func (*Outbound) MultiplexEnabled added in v1.13.15

func (h *Outbound) MultiplexEnabled() bool

func (*Outbound) SetKeepIdleConnections added in v1.14.3

func (h *Outbound) SetKeepIdleConnections(keep bool)

func (*Outbound) Start added in v1.14.3

func (h *Outbound) Start(stage adapter.StartStage, scope *adapter.Scope) error

type RelayInbound

type RelayInbound struct {
	inbound.Adapter
	// contains filtered or unexported fields
}

func (*RelayInbound) NewConnection added in v1.14.0

func (h *RelayInbound) NewConnection(ctx context.Context, conn net.Conn, metadata adapter.InboundContext, onClose N.CloseHandlerFunc)

func (*RelayInbound) NewError

func (h *RelayInbound) NewError(ctx context.Context, err error)

func (*RelayInbound) NewPacket added in v1.14.0

func (h *RelayInbound) NewPacket(buffer *buf.Buffer, source M.Socksaddr)

func (*RelayInbound) Start

func (h *RelayInbound) Start(stage adapter.StartStage, scope *adapter.Scope) error

Jump to

Keyboard shortcuts

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