capable_wrt_inode_uidgid(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… capable_wrt_inode_uidgid(9) πŸ’…

okay so bestie, we're in the Kernel API Manual today and the main character of this page is capable_wrt_inode_uidgid(9). she's a little permission-checking icon and honestly she ate. let's get into it ✨


🌸 NAME 🌸

capable_wrt_inode_uidgid β€” the one that checks nsown_capable and whether the uid and gid are mapped 🫢


✨ SYNOPSIS ✨

bool capable_wrt_inode_uidgid (struct mnt_idmap *idmap , const struct
       inode *inode , int cap );

like, she takes three things and gives you back a bool. simple. elegant. no cap πŸ’–


πŸŽ€ ARGUMENTS πŸŽ€

  • idmap β€” the idmap of the mount that the inode was found from πŸ—ΊοΈ
  • inode β€” the inode in question, the actual subject of the vibe check πŸ‘€
  • cap β€” the capability in question, aka which power we're asking about πŸ‘‘

πŸ¦‹ DESCRIPTION πŸ¦‹

so here's the tea β˜• β€” she returns true if both of these things are true:

  1. the current task has the given capability, targeted at its own user namespace πŸ’«
  2. the given inode's uid and gid are mapped into the current user namespace 🌈

both boxes ticked? true, slay. anything missing? no cap, you're getting a false. periodt πŸ’…


πŸ’œ SEE ALSO πŸ’œ

the whole capability friend group fr fr, go say hi to all of them πŸ§šβ€β™€οΈ


aaaand that's the page! brought to you by the ./kernel girlies, dated October 2026 β€” catch you in the next manpage bestie, mwah πŸ’‹πŸ’–πŸŽ€

πŸ“¦ where this page comes from