conntrack

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RequestQueue = make(chan *netdb.ConntrackTableRequest, 128)

Functions

This section is empty.

Types

type Connection

type Connection struct {
	AF      ipnet.AddressFamily
	SrcIP   netip.Addr
	DstIP   netip.Addr
	DstAddr netip.Addr
	Proto   layers.IPProtocol
	SrcPort uint16
	DstPort uint16
	// contains filtered or unexported fields
}

func ParseHeader

func ParseHeader(pkt []byte) (*Connection, error)

func (*Connection) GetAddressFamily

func (conn *Connection) GetAddressFamily() netdb.AddressFamily

func (*Connection) GetNetConnection

func (conn *Connection) GetNetConnection() *netdb.Connection

func (*Connection) GetProtocol

func (conn *Connection) GetProtocol() netdb.Protocol

func (*Connection) IsActive

func (conn *Connection) IsActive(pktlen int) bool

func (*Connection) IsValid

func (conn *Connection) IsValid(localIPv6 string) bool

func (*Connection) ParseProtocol

func (conn *Connection) ParseProtocol(pkt []byte) error

func (*Connection) ProtoFilter

func (conn *Connection) ProtoFilter() bool

Filter specific proto packet types

type Interface

type Interface interface {
	OutboundConnection(c *Connection, pktlen int)
	Close()

	GetTable(r *netdb.ConntrackTableRequest) *netdb.ConntrackTableResponse
}

func Ctrl

func Ctrl() Interface

Jump to

Keyboard shortcuts

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