trireme-lib: Index | Files

package nfqparser

import ""


Package Files

constants.go nfqlayout.go nfqparser.go

type NFQLayout Uses

type NFQLayout struct {
    QueueNum string
    // process ID of software listening to the queue
    PeerPortID string
    // current number of packets waiting in the queue
    QueueTotal string
    // 0 and 1 only message only provide meta data. If 2, the message provides a part of packet of size copy range.
    CopyMode string
    // length of packet data to put in message
    CopyRange string
    // number of packets dropped because queue was full
    QueueDropped string
    // number of packets dropped because netlink message could not be sent to userspace.
    // If this counter is not zero, try to increase netlink buffer size. On the application side,
    // you will see gap in packet id if netlink message are lost.
    UserDropped string
    // packet id of last packet
    IDSequence string

NFQLayout is the layout of /proc/net/netfilter/nfnetlink_queue

func (*NFQLayout) String Uses

func (n *NFQLayout) String() string

String returns string representation of particular queue

type NFQParser Uses

type NFQParser struct {
    // contains filtered or unexported fields

NFQParser holds nfqparser fields

func NewNFQParser Uses

func NewNFQParser() *NFQParser

NewNFQParser returns nfqparser handler

func (*NFQParser) RetrieveAll Uses

func (n *NFQParser) RetrieveAll() map[string]NFQLayout

RetrieveAll returns all layouts

func (*NFQParser) RetrieveByQueue Uses

func (n *NFQParser) RetrieveByQueue(queueNum string) *NFQLayout

RetrieveByQueue returns layout for a specific queue number

func (*NFQParser) String Uses

func (n *NFQParser) String() string

String returns string renresentation of nfqueue data

func (*NFQParser) Synchronize Uses

func (n *NFQParser) Synchronize() error

Synchronize reads from file and parses it

Package nfqparser imports 6 packages (graph). Updated 2019-03-26. Refresh now. Tools for package owners.