nfq_cfg(3)
β¨ NAME β¨
nfq_cfg β Config helpers π
okay so bestie, this is the little squad of helpers that fills in your netlink messages with all the config bits you need. they're giving "glue code but make it iconic" and honestly? we're obsessed. π
πΈ SYNOPSIS πΈ
Functions π¦
void nfq_nlmsg_cfg_put_cmd (struct nlmsghdr *nlh, uint16_t pf, uint8_t cmd)
void nfq_nlmsg_cfg_put_params (struct nlmsghdr *nlh, uint8_t mode, int range)
void nfq_nlmsg_cfg_put_qmaxlen (struct nlmsghdr *nlh, uint32_t queue_maxlen)
π Detailed Description π
ngl, the title lowkey says it all β these are the config helpers. they do not come with extra lore. periodt. β¨
π Function Documentation π
void nfq_nlmsg_cfg_put_cmd (struct nlmsghdr * nlh, uint16_t pf, uint8_t cmd)
nfq_nlmsg_cfg_put_cmd β adds a netlink config command to your netlink message. it's literally the "hey kernel, here's what I want" button. π₯
Parameters
nlhβ pointer to the netlink messagepfβ packet family (e.g.AF_INET)cmdβ nfqueue nfnetlink command.
Possible commands are: β
NFQNL_CFG_CMD_NONE: do absolutely nothing. which is actually useful, because it lets you check whether the queue subsystem is even working. vibe check for your kernel π«ΆNFQNL_CFG_CMD_BIND: binds the program to a specific queue.NFQNL_CFG_CMD_UNBIND: unbinds the program to a specifiq queue.
Obsolete commands: π
NFQNL_CFG_CMD_PF_BIND: binds to process packets belonging to the given protocol family (ie.PF_INET,PF_INET6, etc).NFQNL_CFG_CMD_PF_UNBIND: unbinds from processing packets belonging to the given protocol family.
π¨ bestie listen β both of those obsolete commands are ignored by Linux kernel 3.8 and later versions. so if you're on anything modern, they're just decoration. do not build your whole personality around them.
Definition at line 166 of file nlmsg.c.
void nfq_nlmsg_cfg_put_params (struct nlmsghdr * nlh, uint8_t mode, int range)
nfq_nlmsg_cfg_put_params β adds a parameter to the netlink message. β¨
Parameters
nlhβ pointer to the netlink messagemodeβ one ofNFQNL_COPY_NONE,NFQNL_COPY_METAorNFQNL_COPY_PACKETrangeβ value of parameter
Definition at line 182 of file nlmsg.c.
void nfq_nlmsg_cfg_put_qmaxlen (struct nlmsghdr * nlh, uint32_t queue_maxlen)
nfq_nlmsg_cfg_put_qmaxlen β adds the queue maximum length to the netlink message. she's the one setting the limit, and honestly? boundaries are hot. π
Parameters
nlhβ pointer to the netlink messagequeue_maxlenβ maximum queue length
Definition at line 197 of file nlmsg.c.
π Author π
Generated automatically by Doxygen for libnetfilter_queue from the source code. (not me writing fanfic about it, it's literally the robot doing its thing π)
and that's the whole page, bestie!! π this was libnetfilter_queue, Version 1.0.5, nfq_cfg(3) β thanks for reading the whole thing, you're so real for that. mwah πβ¨
π¦ where this page comes from
- ubuntu noble: libnetfilter-queue-doc 1.0.5-4build1 Β· GPL-2.0-or-later
- ubuntu questing: libnetfilter-queue-doc 1.0.5-4build1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms