__skb_flow_dissect(9)
π __skb_flow_dissect(9) π
okay bestie, welcome to the Kernel API Manual, and the function we're about to dissect (ha, get it) is __skb_flow_dissect. and before you ask β yes, the name starts with underscores, yes that's a whole vibe, and yes you still have to type them all. no cap. π«Ά
β¨ NAME β¨
__skb_flow_dissect β extract the flow_keys struct and return it. that's literally it. that's the whole job. it gives you the struct. π
π¦ SYNOPSIS π¦
bool __skb_flow_dissect (const struct net *net , const struct sk_buff
*skb , struct flow_dissector *flow_dissector , void *target_container ,
const void *data , __be16 proto , int nhoff , int hlen , unsigned int
flags );
like, nine arguments. nine. she's high-maintenance but she's worth it, i promise π
πΈ ARGUMENTS πΈ
okay so every single one of these, one by one, no skipping, we don't do that here:
netβ the associated network namespace. and if it'sNULL? it gets derived fromskbinstead. self-sufficient queen behavior πskbβ thesk_buffwe're extracting the flow from. you can passNULLhere, but only if you've specified everything else. like, she can be absent, but only if the rest of the squad shows up πflow_dissectorβ the list of keys to dissect. this is the whole to-do list, basically πtarget_containerβ the target structure where the dissected values get put. the drop-off spot. the lil home for your results πdataβ raw buffer pointer to the packet. if it'sNULL, we useskb->datainstead β¨protoβ the protocol for which to get the flow. ifdataisNULL, we useskb->protocolπ¦nhoffβ the network header offset. ifdataisNULL, we useskb_network_offset(skb)πhlenβ the packet header length. ifdataisNULL, we useskb_headlen(skb)πflagsβ the flags that control the dissection process, e.g.FLOW_DISSECTOR_F_STOP_AT_ENCAP. these are the settings, the knobs, the little dials that change the whole mood ποΈ
π DESCRIPTION π
so the way that this works is: the function will try to retrieve individual keys into the target specified by flow_dissector β and it'll pull them from either the skbuff or a raw buffer specified by the rest parameters. either/or, bestie, it's flexible like that π
β οΈ real talk though: the caller must take care of zeroing target container memory. that's on you, not on her. she is not doing your homework. not me forgetting to zero and then debugging for three hours π
π₯ SEE ALSO π₯
the extended universe, aka go read these too:
- Kernel file
./net/core/flow_dissector.c skb_flow_get_ports(9)skb_flow_get_icmp_tci(9)__skb_flow_dissect_batadv(9)__skb_get_hash_net(9)skb_get_poff(9)
okay that's the whole page, mwah π this one's coming to you live from ./net/core, dated October 2026, and it's filed under __skb_flow_dissect(9) forever and always. go dissect some flows, you've got this π§ β
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms