Documentation ¶
Overview ¶
Package netfilter provides Go bindings for libnetfilter_queue This library provides access to packets in the IPTables netfilter queue (NFQUEUE). The libnetfilter_queue library is part of the http://netfilter.org/projects/libnetfilter_queue/ project.
Index ¶
Constants ¶
View Source
const ( //AfInet Address Family Inet AfInet = 2 //NfDrop Net filter verdict NfDrop verdictType = 0 // nolint //NfAccept Net filter verdict NfAccept verdictType = 1 //nolint //NfStolen Net filter verdict NfStolen verdictType = 2 // nolint //NfQueue Net filter verdict NfQueue verdictType = 3 // nolint //NfRepeat Net filter verdict NfRepeat verdictType = 4 // nolint //NfStop Net filter verdict NfStop verdictType = 5 // nolint //NfDefaultPacketSize default packet size NfDefaultPacketSize uint32 = 0xffff )
Variables ¶
This section is empty.
Functions ¶
func SetVerdict ¶
SetVerdict receives the response from the processor, copies the buffers and passes the result to the C code
Types ¶
type NFPacket ¶
type NFPacket struct { Buffer []byte Mark string Xbuffer *C.uchar QueueHandle *C.struct_nfq_q_handle ID int }
NFPacket structure holds the packet
type NFQueue ¶
type NFQueue struct { Packets chan *NFPacket // contains filtered or unexported fields }
NFQueue implements the queue and holds all related state information
func NewNFQueue ¶
NewNFQueue creates and bind to queue specified by queueID.
Click to show internal directories.
Click to hide internal directories.