sk_net_capable(9)
π¦ NAME π¦
sk_net_capable β the whole vibe is a Network namespace socket capability test, and yes bestie, we're doing kernel socket capability lore today π
omg hi, welcome to Kernel API Manual territory, specifically sk_net_capable(9) β it's giving very niche, very powerful, very "iykyk" energy π
β¨
β¨ SYNOPSIS β¨
bool sk_net_capable (const struct sock *sk , int cap );
π ARGUMENTS π
skβ the socket you're using a capability on or through, bestie π«Άcapβ the capability you're using, periodt π«
πΈ DESCRIPTION πΈ
okay so picture this: a socket exists, and we need a capability vibe check π
sk_net_capable() is the test that checks whether the opener of the socket had the capability when the socket was created and whether the current process has the capability cap over the network namespace that the socket is a member of. That's literally the whole thing β no cap π§’, just capability logic, and it's lowkey iconic π
It's checking both sides of the story: the opener-at-creation situation and the current process situation. slay π¦
π SEE ALSO π
Kernel file ./net/core/sock.c is the mothership, and then there's this whole friend group:
- Kernel file
./net/core/sock.c sk_ns_capable(9)sk_capable(9)sk_set_memalloc(9)sk_alloc(9)sk_clone(9)skb_page_frag_refill(9)sk_wait_data(9)__sk_mem_raise_allocated(9)__sk_mem_schedule(9)__sk_mem_reduce_allocated(9)__sk_mem_reclaim(9)
xoxo π this page is from ./net/core, dated October 2026, and it's literally called sk_net_capable(9) β see u in the kernel, bestie π«Άβ¨<ο½endβofβthinkingο½># π¦ NAME π¦
sk_net_capable β the whole vibe is a Network namespace socket capability test, and yes bestie, we're doing kernel socket capability lore today π
omg hi, welcome to Kernel API Manual territory, specifically sk_net_capable(9) β it's giving very niche, very powerful, very "iykyk" energy π
β¨
β¨ SYNOPSIS β¨
bool sk_net_capable (const struct sock *sk , int cap );
π ARGUMENTS π
skβ the socket you're using a capability on or through, bestie π«Άcapβ the capability you're using, periodt π«
πΈ DESCRIPTION πΈ
okay so picture this: a socket exists, and we need a capability vibe check π
sk_net_capable() is the test that checks whether the opener of the socket had the capability when the socket was created and whether the current process has the capability cap over the network namespace that the socket is a member of. That's literally the whole thing β no cap π§’, just capability logic, and it's lowkey iconic π
It's checking both sides of the story: the opener-at-creation situation and the current process situation. slay π¦
π SEE ALSO π
Kernel file ./net/core/sock.c is the mothership, and then there's this whole friend group:
- Kernel file
./net/core/sock.c sk_ns_capable(9)sk_capable(9)sk_set_memalloc(9)sk_alloc(9)sk_clone(9)skb_page_frag_refill(9)sk_wait_data(9)__sk_mem_raise_allocated(9)__sk_mem_schedule(9)__sk_mem_reduce_allocated(9)__sk_mem_reclaim(9)
xoxo π this page is from ./net/core, dated October 2026, and it's literally called sk_net_capable(9) β see u in the kernel, bestie π«Άβ¨
π¦ 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