relay

package
v0.0.0-...-3149a5f Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IPv4mcast = "224.0.0.0"
)

Variables

This section is empty.

Functions

func StartRaw

func StartRaw()

Types

type Relay

type Relay struct {
	Group               *net.UDPAddr
	IfiRecvList         []*net.Interface
	IfiSendList         []*net.Interface
	IfiReflectList      []*net.Interface
	AcceptUnicast       bool
	ProxyRequests       bool
	ProxyReplies        bool
	RequestSrcPortReuse bool
	ReplySrcPortReuse   bool
	ResponseTimeout     time.Duration
	StatsInterval       time.Duration
	Logger              logging.Logger
	TerminationFunction func()
	// contains filtered or unexported fields
}

func (*Relay) GetStats

func (r *Relay) GetStats() (rs RelayStats)

func (*Relay) Initialize

func (r *Relay) Initialize()

func (*Relay) LogStats

func (r *Relay) LogStats(reason string)

func (*Relay) Run

func (r *Relay) Run()

func (*Relay) Start

func (r *Relay) Start(wait bool)

func (*Relay) Stop

func (r *Relay) Stop(wait bool)

func (*Relay) Validate

func (r *Relay) Validate(fatal bool) bool

type RelayStats

type RelayStats struct {
	TotalRequests         uint64 `json:"total_requests"`
	TotalReplies          uint64 `json:"total_replies"`
	ForwardedRequests     uint64 `json:"forwarded_requests"`
	ForwardedReplies      uint64 `json:"forwarded_replies"`
	ProxiedRequests       uint64 `json:"proxied_requests"`
	ProxiedReplies        uint64 `json:"proxied_replies"`
	SrcPortReusedRequests uint64 `json:"src_port_reused_requests"`
	SrcPortReusedReplies  uint64 `json:"src_port_reused_replies"`
	UnicastRequests       uint64 `json:"unicast_requests"`
	MulticastRequests     uint64 `json:"multicast_requests"`
	PacketsReceived       uint64 `json:"packets_received"`
	PacketsSent           uint64 `json:"packets_sent"`
	BytesReceived         uint64 `json:"bytes_received"`
	BytesSent             uint64 `json:"bytes_sent"`
}

Jump to

Keyboard shortcuts

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