netfilter
firewalling, NAT, and packet mangling for linux
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
nfnl.c File Reference
Include dependency graph for nfnl.c:

Functions

Socket Creating
int nfnl_connect (struct nl_sock *sk)
 Create and connect netfilter netlink socket. More...
 
Sending
int nfnl_send_simple (struct nl_sock *sk, uint8_t subsys_id, uint8_t type, int flags, uint8_t family, uint16_t res_id)
 Send trivial netfilter netlink message. More...
 
Message Parsing
uint8_t nfnlmsg_subsys (struct nlmsghdr *nlh)
 Get netfilter subsystem id from message. More...
 
uint8_t nfnlmsg_subtype (struct nlmsghdr *nlh)
 Get netfilter message type from message. More...
 
uint8_t nfnlmsg_family (struct nlmsghdr *nlh)
 Get netfilter family from message. More...
 
uint16_t nfnlmsg_res_id (struct nlmsghdr *nlh)
 Get netfilter resource id from message. More...
 
Message Building
struct nl_msgnfnlmsg_alloc_simple (uint8_t subsys_id, uint8_t type, int flags, uint8_t family, uint16_t res_id)
 Allocate a new netfilter netlink message. More...
 
int nfnlmsg_put (struct nl_msg *msg, uint32_t pid, uint32_t seq, uint8_t subsys_id, uint8_t type, int flags, uint8_t family, uint16_t res_id)
 Add netlink and netfilter netlink headers to netlink message. More...