Functions | |
struct nlmsghdr * | nfacct_nlmsg_build_hdr (char *buf, uint8_t cmd, uint16_t flags, uint32_t seq) |
void | nfacct_nlmsg_build_payload (struct nlmsghdr *nlh, struct nfacct *nfacct) |
int | nfacct_nlmsg_parse_payload (const struct nlmsghdr *nlh, struct nfacct *nfacct) |
struct nlmsghdr* nfacct_nlmsg_build_hdr | ( | char * | buf, | |
uint8_t | cmd, | |||
uint16_t | flags, | |||
uint32_t | seq | |||
) | [read] |
nfacct_nlmsg_build_hdr - build netlink message header for nfacct subsystem
buf,: | buffer where this function outputs the netlink message. | |
cmd,: | nfacct nfnetlink command. | |
flags,: | netlink flags. | |
seq,: | sequence number for this message. |
Possible commands:
Examples:
Definition at line 318 of file libnetfilter_acct.c.
void nfacct_nlmsg_build_payload | ( | struct nlmsghdr * | nlh, | |
struct nfacct * | nfacct | |||
) |
nfacct_nlmsg_build_payload - build payload from accounting object
nlh,: | netlink message that you want to use to add the payload. | |
nfacct,: | pointer to a accounting object |
Definition at line 342 of file libnetfilter_acct.c.
int nfacct_nlmsg_parse_payload | ( | const struct nlmsghdr * | nlh, | |
struct nfacct * | nfacct | |||
) |
nfacct_nlmsg_parse_payload - set accounting object attributes from message
nlh,: | netlink message that you want to use to add the payload. | |
nfacct,: | pointer to a accounting object |
This function returns -1 in case that some mandatory attributes are missing. On sucess, it returns 0.
Definition at line 396 of file libnetfilter_acct.c.