common_perm_dir_dentry(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ common_perm_dir_dentry(9) πŸ¦‹

okay so bestie, this is section (9) of the Kernel API Manual β€” yes, the kernel API manual, we’re in the big leagues now πŸ’…. This page is literally about common_perm_dir_dentry, the common permission wrapper for when the path is a dir and the thing is a dentry. It’s giving β€œpermission check but make it directory/dentry specific,” and honestly? iconic. Let’s go 🫢✨

✨ NAME ✨

common_perm_dir_dentry β€” common permission wrapper when path is dir, dentry. That’s the whole vibe: it’s the wrapper that handles the permission check when you’ve got a directory path and a dentry. No cap 🧚

🌸 SYNOPSIS 🌸

int common_perm_dir_dentry (const char *op , const struct path *dir ,
       struct dentry *dentry , u32 mask , struct path_cond *cond );

πŸŽ€ ARGUMENTS πŸŽ€

okay bestie, here’s the cast β€” every single one matters:

  • op β€” operation being checked. Like, what are we even doing here? This tells you πŸ‘€
  • dir β€” directory of the dentry. NOT NULL, bestie β€” do not come in here with a null, fr fr πŸ™ˆ
  • dentry β€” dentry to check. Also NOT NULL β€” the audacity of a null dentry? not today πŸ’€
  • mask β€” requested permissions mask. The permissions wishlist, basically πŸŽ€
  • cond β€” conditional info for the permission request. NOT NULL β€” it’s required, no skipping 😀
the NOT NULL tags are not decorative, bestie β€” they’re the whole vibe check 🚨

πŸ’– RETURN πŸ’–

Returns 0 β€” slay βœ…. Otherwise you get an error code if there’s an error or permission was denied. That’s it, that’s the tea β˜•πŸ’…

🌈 SEE ALSO 🌈

Kernel file ./security/apparmor/lsm.c β€” and the whole squad is:


mwah πŸ’‹ this page lives under ./security/apparmor, is dated October 2026, and is literally common_perm_dir_dentry(9). byeee, go check those permissions bestie 🫢🌈

πŸ“¦ where this page comes from