udphop

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: GPL-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewUDPHopPacketConn

func NewUDPHopPacketConn(addrStr string, hopPorts string, hopInterval time.Duration, listenPacket ListenPacketFunc) (net.PacketConn, error)

Types

type InvalidPortError

type InvalidPortError struct {
	PortStr string
}

func (InvalidPortError) Error

func (e InvalidPortError) Error() string

type ListenPacketFunc

type ListenPacketFunc func() (net.PacketConn, error)

type UDPHopAddr

type UDPHopAddr struct {
	IP      net.IP
	Ports   []uint16
	PortStr string
}

UDPHopAddr contains an IP address and a list of ports.

func ResolveUDPHopAddr

func ResolveUDPHopAddr(addr, portStr string) (*UDPHopAddr, error)

func (*UDPHopAddr) Network

func (a *UDPHopAddr) Network() string

func (*UDPHopAddr) String

func (a *UDPHopAddr) String() string

Jump to

Keyboard shortcuts

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