avc_lookup(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… avc_lookup β€” aka the Kernel API Manual's avc_lookup(9) page πŸŽ€

Okay bestie, gather round, because this one is a little lookup function that has main character energy and honestly? It eats. ✨


🌸 NAME 🌸

avc_lookup β€” literally just: look up an AVC entry. That's the whole vibe check. πŸ‘‘


✨ SYNOPSIS ✨

struct avc_node * avc_lookup (u32 ssid , u32 tsid , u16 tclass );

Yes, it returns a struct avc_node *. Yes, it takes three args. No, we're not skipping any of them, keep reading. 🫢


πŸ¦‹ ARGUMENTS πŸ¦‹

  • ssid β€” the source security identifier. Like, who's the one doing the thing. 🌈
  • tsid β€” the target security identifier. Like, who's on the receiving end. 🎯
  • tclass β€” the target security class. It's giving "what kind of object are we even talking about". πŸ’œ

🌸 DESCRIPTION 🌸

So here's the tea, bestie: this function goes looking for an AVC entry that's valid for the (ssid, tsid) pair, and it interprets the permissions based on tclass. Not me explaining permissions as if they're a personality trait 😭

If a valid AVC entry exists, then this function returns the avc_node. Slay. Iconic. Returned.

Otherwise? This function returns NULL. πŸ’€ That's it, that's the whole twist. No drama, just NULL.


🧚 SEE ALSO 🧚

Kernel file ./security/selinux/avc.c β€” plus the whole friend group:

Fr fr, that's the entire invite list. πŸ’–


Okay byeee, this page is brought to you by ./security/selinux and it's dated October 2026 β€” and honestly, avc_lookup(9) said "periodt". πŸ’…πŸ”₯

πŸ“¦ where this page comes from