forwarder

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseFlowDescIPNet

func ParseFlowDescIPNet(s string) (*net.IPNet, error)

func ParseFlowDescPorts

func ParseFlowDescPorts(s string) ([][]uint16, error)

Types

type Driver

type Driver interface {
	Close()

	CreatePDR(uint64, *ie.IE) error
	UpdatePDR(uint64, *ie.IE) error
	RemovePDR(uint64, *ie.IE) error

	CreateFAR(uint64, *ie.IE) error
	UpdateFAR(uint64, *ie.IE) error
	RemoveFAR(uint64, *ie.IE) error

	CreateQER(uint64, *ie.IE) error
	UpdateQER(uint64, *ie.IE) error
	RemoveQER(uint64, *ie.IE) error

	CreateURR(uint64, *ie.IE) error
	UpdateURR(uint64, *ie.IE) ([]report.USAReport, error)
	RemoveURR(uint64, *ie.IE) ([]report.USAReport, error)
	QueryURR(uint64, uint32) ([]report.USAReport, error)

	CreateBAR(uint64, *ie.IE) error
	UpdateBAR(uint64, *ie.IE) error
	RemoveBAR(uint64, *ie.IE) error

	HandleReport(report.Handler)
}

func NewDriver

func NewDriver(wg *sync.WaitGroup, cfg *factory.Config) (Driver, error)

type Empty

type Empty struct{}

func (Empty) Close

func (Empty) Close()

func (Empty) CreateBAR

func (Empty) CreateBAR(uint64, *ie.IE) error

func (Empty) CreateFAR

func (Empty) CreateFAR(uint64, *ie.IE) error

func (Empty) CreatePDR

func (Empty) CreatePDR(uint64, *ie.IE) error

func (Empty) CreateQER

func (Empty) CreateQER(uint64, *ie.IE) error

func (Empty) CreateURR

func (Empty) CreateURR(uint64, *ie.IE) error

func (Empty) HandleReport

func (Empty) HandleReport(report.Handler)

func (Empty) QueryURR added in v1.1.0

func (Empty) QueryURR(uint64, uint32) ([]report.USAReport, error)

func (Empty) RemoveBAR

func (Empty) RemoveBAR(uint64, *ie.IE) error

func (Empty) RemoveFAR

func (Empty) RemoveFAR(uint64, *ie.IE) error

func (Empty) RemovePDR

func (Empty) RemovePDR(uint64, *ie.IE) error

func (Empty) RemoveQER

func (Empty) RemoveQER(uint64, *ie.IE) error

func (Empty) RemoveURR

func (Empty) RemoveURR(uint64, *ie.IE) ([]report.USAReport, error)

func (Empty) UpdateBAR

func (Empty) UpdateBAR(uint64, *ie.IE) error

func (Empty) UpdateFAR

func (Empty) UpdateFAR(uint64, *ie.IE) error

func (Empty) UpdatePDR

func (Empty) UpdatePDR(uint64, *ie.IE) error

func (Empty) UpdateQER

func (Empty) UpdateQER(uint64, *ie.IE) error

func (Empty) UpdateURR

func (Empty) UpdateURR(uint64, *ie.IE) ([]report.USAReport, error)

type FlowDesc

type FlowDesc struct {
	Action   string
	Dir      string
	Proto    uint8
	Src      *net.IPNet
	Dst      *net.IPNet
	SrcPorts [][]uint16
	DstPorts [][]uint16
}

func ParseFlowDesc

func ParseFlowDesc(s string) (*FlowDesc, error)

type Gtp5g

type Gtp5g struct {
	// contains filtered or unexported fields
}

func OpenGtp5g

func OpenGtp5g(wg *sync.WaitGroup, addr string, mtu uint32) (*Gtp5g, error)

func (*Gtp5g) Close

func (g *Gtp5g) Close()

func (*Gtp5g) CreateBAR

func (g *Gtp5g) CreateBAR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) CreateFAR

func (g *Gtp5g) CreateFAR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) CreatePDR

func (g *Gtp5g) CreatePDR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) CreateQER

func (g *Gtp5g) CreateQER(lSeid uint64, req *ie.IE) error

func (*Gtp5g) CreateURR

func (g *Gtp5g) CreateURR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) HandleReport

func (g *Gtp5g) HandleReport(handler report.Handler)
func (g *Gtp5g) Link() *Gtp5gLink

func (*Gtp5g) QueryMultiURR added in v1.2.0

func (g *Gtp5g) QueryMultiURR(lSeidUrridsMap map[uint64][]uint32) (map[uint64][]report.USAReport, error)

func (*Gtp5g) QueryURR added in v1.1.0

func (g *Gtp5g) QueryURR(lSeid uint64, urrid uint32) ([]report.USAReport, error)

func (*Gtp5g) RemoveBAR

func (g *Gtp5g) RemoveBAR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) RemoveFAR

func (g *Gtp5g) RemoveFAR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) RemovePDR

func (g *Gtp5g) RemovePDR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) RemoveQER

func (g *Gtp5g) RemoveQER(lSeid uint64, req *ie.IE) error

func (*Gtp5g) RemoveURR

func (g *Gtp5g) RemoveURR(lSeid uint64, req *ie.IE) ([]report.USAReport, error)

func (*Gtp5g) UpdateBAR

func (g *Gtp5g) UpdateBAR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) UpdateFAR

func (g *Gtp5g) UpdateFAR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) UpdatePDR

func (g *Gtp5g) UpdatePDR(lSeid uint64, req *ie.IE) error

func (*Gtp5g) UpdateQER

func (g *Gtp5g) UpdateQER(lSeid uint64, req *ie.IE) error

func (*Gtp5g) UpdateURR

func (g *Gtp5g) UpdateURR(lSeid uint64, req *ie.IE) ([]report.USAReport, error)

func (*Gtp5g) WritePacket

func (g *Gtp5g) WritePacket(far *gtp5gnl.FAR, qer *gtp5gnl.QER, pkt []byte) error
type Gtp5gLink struct {
	// contains filtered or unexported fields
}
func OpenGtp5gLink(mux *nl.Mux, addr string, mtu uint32, log *logrus.Entry) (*Gtp5gLink, error)

func (*Gtp5gLink) Close

func (g *Gtp5gLink) Close()

func (*Gtp5gLink) RouteAdd

func (g *Gtp5gLink) RouteAdd(dst *net.IPNet) error

func (*Gtp5gLink) WriteTo

func (g *Gtp5gLink) WriteTo(b []byte, addr net.Addr) (int, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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