netc

package
v0.13.2 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DNSSECEncoding = base32.NewEncoding("0123456789abcdefghijklmnopqrstuv").WithPadding(base32.NoPadding)

Functions

func AddrFromNet

func AddrFromNet(addr net.Addr) (netip.Addr, error)

func AddrPortFromNet

func AddrPortFromNet(addr net.Addr) (netip.AddrPort, error)

func GenDomainName

func GenDomainName(realm string) string

func GenName

func GenName() string

func IPFromNet

func IPFromNet(addr net.Addr) (net.IP, error)

func IsSubdomain

func IsSubdomain(domain string, realm string) bool

func LocalAddrs

func LocalAddrs() ([]netip.Addr, error)

func ParseCIDR

func ParseCIDR(str string) (netip.Prefix, error)

func ParseCIDRs

func ParseCIDRs(strs []string) ([]netip.Prefix, error)

Types

type Joiner

type Joiner struct {
	Accept func(context.Context) (net.Conn, error)
	Dial   func(context.Context) (net.Conn, error)
	Join   func(ctx context.Context, acceptConn net.Conn, dialConn net.Conn)
}

func (*Joiner) Run

func (j *Joiner) Run(ctx context.Context) error

Jump to

Keyboard shortcuts

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