netfilter
firewalling, NAT, and packet mangling for linux
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
queue_msg_obj.c File Reference
#include <netlink-local.h>
#include <netlink/netfilter/nfnl.h>
#include <netlink/netfilter/netfilter.h>
#include <netlink/netfilter/queue_msg.h>
#include <linux/netfilter.h>
Include dependency graph for queue_msg_obj.c:

Functions

Allocation/Freeing
struct nfnl_queue_msgnfnl_queue_msg_alloc (void)
 
void nfnl_queue_msg_get (struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_put (struct nfnl_queue_msg *msg)
 

Variables

struct nl_object_ops queue_msg_obj_ops
 

Attributes

void nfnl_queue_msg_set_group (struct nfnl_queue_msg *msg, uint16_t group)
 
int nfnl_queue_msg_test_group (const struct nfnl_queue_msg *msg)
 
uint16_t nfnl_queue_msg_get_group (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_family (struct nfnl_queue_msg *msg, uint8_t family)
 Set the protocol family. More...
 
int nfnl_queue_msg_test_family (const struct nfnl_queue_msg *msg)
 
uint8_t nfnl_queue_msg_get_family (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_packetid (struct nfnl_queue_msg *msg, uint32_t packetid)
 
int nfnl_queue_msg_test_packetid (const struct nfnl_queue_msg *msg)
 
uint32_t nfnl_queue_msg_get_packetid (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_hwproto (struct nfnl_queue_msg *msg, uint16_t hwproto)
 
int nfnl_queue_msg_test_hwproto (const struct nfnl_queue_msg *msg)
 
uint16_t nfnl_queue_msg_get_hwproto (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_hook (struct nfnl_queue_msg *msg, uint8_t hook)
 
int nfnl_queue_msg_test_hook (const struct nfnl_queue_msg *msg)
 
uint8_t nfnl_queue_msg_get_hook (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_mark (struct nfnl_queue_msg *msg, uint32_t mark)
 
int nfnl_queue_msg_test_mark (const struct nfnl_queue_msg *msg)
 
uint32_t nfnl_queue_msg_get_mark (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_timestamp (struct nfnl_queue_msg *msg, struct timeval *tv)
 
int nfnl_queue_msg_test_timestamp (const struct nfnl_queue_msg *msg)
 
const struct timeval * nfnl_queue_msg_get_timestamp (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_indev (struct nfnl_queue_msg *msg, uint32_t indev)
 
int nfnl_queue_msg_test_indev (const struct nfnl_queue_msg *msg)
 
uint32_t nfnl_queue_msg_get_indev (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_outdev (struct nfnl_queue_msg *msg, uint32_t outdev)
 
int nfnl_queue_msg_test_outdev (const struct nfnl_queue_msg *msg)
 
uint32_t nfnl_queue_msg_get_outdev (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_physindev (struct nfnl_queue_msg *msg, uint32_t physindev)
 
int nfnl_queue_msg_test_physindev (const struct nfnl_queue_msg *msg)
 
uint32_t nfnl_queue_msg_get_physindev (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_physoutdev (struct nfnl_queue_msg *msg, uint32_t physoutdev)
 
int nfnl_queue_msg_test_physoutdev (const struct nfnl_queue_msg *msg)
 
uint32_t nfnl_queue_msg_get_physoutdev (const struct nfnl_queue_msg *msg)
 
void nfnl_queue_msg_set_hwaddr (struct nfnl_queue_msg *msg, uint8_t *hwaddr, int len)
 
int nfnl_queue_msg_test_hwaddr (const struct nfnl_queue_msg *msg)
 
const uint8_t * nfnl_queue_msg_get_hwaddr (const struct nfnl_queue_msg *msg, int *len)
 
int nfnl_queue_msg_set_payload (struct nfnl_queue_msg *msg, uint8_t *payload, int len)
 
int nfnl_queue_msg_test_payload (const struct nfnl_queue_msg *msg)
 
const void * nfnl_queue_msg_get_payload (const struct nfnl_queue_msg *msg, int *len)
 
void nfnl_queue_msg_set_verdict (struct nfnl_queue_msg *msg, unsigned int verdict)
 Return the number of items matching a filter in the cache. More...
 
int nfnl_queue_msg_test_verdict (const struct nfnl_queue_msg *msg)
 
unsigned int nfnl_queue_msg_get_verdict (const struct nfnl_queue_msg *msg)
 

Function Documentation

struct nfnl_queue_msg* nfnl_queue_msg_alloc ( void  )

References nl_object_alloc(), and queue_msg_obj_ops.

Referenced by nfnlmsg_queue_msg_parse().

Here is the call graph for this function:

Here is the caller graph for this function:

void nfnl_queue_msg_get ( struct nfnl_queue_msg msg)

References nl_object_get().

Here is the call graph for this function:

uint8_t nfnl_queue_msg_get_family ( const struct nfnl_queue_msg msg)

References nfnl_queue_msg::queue_msg_family.

Referenced by nfnl_queue_msg_build_verdict().

Here is the caller graph for this function:

uint16_t nfnl_queue_msg_get_group ( const struct nfnl_queue_msg msg)

References nfnl_queue_msg::queue_msg_group.

Referenced by nfnl_queue_msg_build_verdict().

Here is the caller graph for this function:

uint8_t nfnl_queue_msg_get_hook ( const struct nfnl_queue_msg msg)
const uint8_t* nfnl_queue_msg_get_hwaddr ( const struct nfnl_queue_msg msg,
int *  len 
)
uint16_t nfnl_queue_msg_get_hwproto ( const struct nfnl_queue_msg msg)
uint32_t nfnl_queue_msg_get_indev ( const struct nfnl_queue_msg msg)
uint32_t nfnl_queue_msg_get_mark ( const struct nfnl_queue_msg msg)

References nfnl_queue_msg::queue_msg_mark.

Referenced by nfnl_queue_msg_build_verdict().

Here is the caller graph for this function:

uint32_t nfnl_queue_msg_get_outdev ( const struct nfnl_queue_msg msg)
uint32_t nfnl_queue_msg_get_packetid ( const struct nfnl_queue_msg msg)

References nfnl_queue_msg::queue_msg_packetid.

Referenced by nfnl_queue_msg_build_verdict().

Here is the caller graph for this function:

const void* nfnl_queue_msg_get_payload ( const struct nfnl_queue_msg msg,
int *  len 
)
uint32_t nfnl_queue_msg_get_physindev ( const struct nfnl_queue_msg msg)
uint32_t nfnl_queue_msg_get_physoutdev ( const struct nfnl_queue_msg msg)
const struct timeval* nfnl_queue_msg_get_timestamp ( const struct nfnl_queue_msg msg)
unsigned int nfnl_queue_msg_get_verdict ( const struct nfnl_queue_msg msg)

References nfnl_queue_msg::queue_msg_verdict.

Referenced by nfnl_queue_msg_build_verdict().

Here is the caller graph for this function:

void nfnl_queue_msg_put ( struct nfnl_queue_msg msg)

References nl_object_put().

Referenced by nfnlmsg_queue_msg_parse().

Here is the call graph for this function:

Here is the caller graph for this function:

void nfnl_queue_msg_set_family ( struct nfnl_queue_msg msg,
uint8_t  family 
)

Set the protocol family.

  • msg NF queue message
  • family AF_XXX address family example: AF_INET, AF_UNIX, etc

References nfnl_queue_msg::queue_msg_family.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_group ( struct nfnl_queue_msg msg,
uint16_t  group 
)

References nfnl_queue_msg::queue_msg_group.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_hook ( struct nfnl_queue_msg msg,
uint8_t  hook 
)

References hook, and nfnl_queue_msg::queue_msg_hook.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_hwaddr ( struct nfnl_queue_msg msg,
uint8_t *  hwaddr,
int  len 
)

References len, nfnl_queue_msg::queue_msg_hwaddr, and nfnl_queue_msg::queue_msg_hwaddr_len.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_hwproto ( struct nfnl_queue_msg msg,
uint16_t  hwproto 
)

References nfnl_queue_msg::queue_msg_hwproto.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_indev ( struct nfnl_queue_msg msg,
uint32_t  indev 
)

References nfnl_queue_msg::queue_msg_indev.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_mark ( struct nfnl_queue_msg msg,
uint32_t  mark 
)

References mark, and nfnl_queue_msg::queue_msg_mark.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_outdev ( struct nfnl_queue_msg msg,
uint32_t  outdev 
)

References nfnl_queue_msg::queue_msg_outdev.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_packetid ( struct nfnl_queue_msg msg,
uint32_t  packetid 
)

References nfnl_queue_msg::queue_msg_packetid.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

int nfnl_queue_msg_set_payload ( struct nfnl_queue_msg msg,
uint8_t *  payload,
int  len 
)

References len, NLE_NOMEM, nfnl_queue_msg::queue_msg_payload, and nfnl_queue_msg::queue_msg_payload_len.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_physindev ( struct nfnl_queue_msg msg,
uint32_t  physindev 
)

References nfnl_queue_msg::queue_msg_physindev.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_physoutdev ( struct nfnl_queue_msg msg,
uint32_t  physoutdev 
)

References nfnl_queue_msg::queue_msg_physoutdev.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_timestamp ( struct nfnl_queue_msg msg,
struct timeval *  tv 
)

References nfnl_queue_msg::queue_msg_timestamp.

Referenced by nfnlmsg_queue_msg_parse().

Here is the caller graph for this function:

void nfnl_queue_msg_set_verdict ( struct nfnl_queue_msg msg,
unsigned int  verdict 
)

Return the number of items matching a filter in the cache.

  • msg queue msg
  • verdict NF_DROP, NF_ACCEPT, NF_REPEAT, etc

References nfnl_queue_msg::queue_msg_verdict, and verdict.

int nfnl_queue_msg_test_family ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_group ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_hook ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_hwaddr ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_hwproto ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_indev ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_mark ( const struct nfnl_queue_msg msg)

Referenced by nfnl_queue_msg_build_verdict().

Here is the caller graph for this function:

int nfnl_queue_msg_test_outdev ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_packetid ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_payload ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_physindev ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_physoutdev ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_timestamp ( const struct nfnl_queue_msg msg)
int nfnl_queue_msg_test_verdict ( const struct nfnl_queue_msg msg)

Variable Documentation

struct nl_object_ops queue_msg_obj_ops
Initial value:
= {
.oo_name = "netfilter/queuemsg",
.oo_size = sizeof(struct nfnl_queue_msg),
.oo_free_data = nfnl_queue_msg_free_data,
.oo_clone = nfnl_queue_msg_clone,
.oo_dump = {
[NL_DUMP_LINE] = nfnl_queue_msg_dump,
[NL_DUMP_DETAILS] = nfnl_queue_msg_dump,
[NL_DUMP_STATS] = nfnl_queue_msg_dump,
},
.oo_attrs2str = nfnl_queue_msg_attrs2str,
}
Dump object briefly on one line.
Definition: types.h:22
Definition: netlink-types.h:808
Dump all attributes but no statistics.
Definition: types.h:23
Dump all attributes including statistics.
Definition: types.h:24

Referenced by nfnl_queue_msg_alloc().