sing

package
v1.16.4 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2023 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const UDPTimeout = 5 * time.Minute

Variables

This section is empty.

Functions

func ConvertMetadata

func ConvertMetadata(metadata *C.Metadata) M.Metadata

func ShouldIgnorePacketError

func ShouldIgnorePacketError(err error) bool

func UpstreamMetadata

func UpstreamMetadata(metadata M.Metadata) M.Metadata

func WithAdditions

func WithAdditions(ctx context.Context, additions ...inbound.Addition) context.Context

Types

type ListenerHandler

type ListenerHandler struct {
	Tunnel     C.Tunnel
	Type       C.Type
	Additions  []inbound.Addition
	UDPTimeout time.Duration
}

func (*ListenerHandler) IsSpecialFqdn

func (h *ListenerHandler) IsSpecialFqdn(fqdn string) bool

func (*ListenerHandler) NewConnection

func (h *ListenerHandler) NewConnection(ctx context.Context, conn net.Conn, metadata M.Metadata) error

func (*ListenerHandler) NewError

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

func (*ListenerHandler) NewPacketConnection

func (h *ListenerHandler) NewPacketConnection(ctx context.Context, conn network.PacketConn, metadata M.Metadata) error

func (*ListenerHandler) ParseSpecialFqdn

func (h *ListenerHandler) ParseSpecialFqdn(ctx context.Context, conn net.Conn, metadata M.Metadata) error

Jump to

Keyboard shortcuts

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