smk_curacc(9)
π smk_curacc(9) β like, the Kernel API Manual one, bestie
okay so real talk, this is smk_curacc from section 9 of the Kernel API Manual and it's literally the vibes-check function for Smack access. buckle up π
β¨ NAME β¨
smk_curacc β determine if current has a specific access to an object π«Ά
(yes that's the whole name section, she said what she said)
πΈ SYNOPSIS πΈ
int smk_curacc (struct smack_known *obj_known , u32 mode , struct
smk_audit_info *a );
that's the signature, copy it exactly, no cap π
π¦ ARGUMENTS π¦
obj_knownβ a pointer to the object's Smack label entry. like, the label of the thing you're trying to touch β¨modeβ the access requested, in "MAY" format π₯aβ common audit data π
π DESCRIPTION π
so what she does is: this function checks the current subject label/object label pair in the access rule list, and returns 0 if the access is permitted, non zero otherwise. iconic behaviour honestly.
and the little bonus: it allows that current may have the capability to override the rules. main character energy, she can skip the line if she's got the cap π
β SEE ALSO β
- Kernel file
./security/smack/smack_access.cβ the whole squad lives here π smk_access_entry(9)smk_access(9)smk_tskacc(9)smack_str_from_perm(9)smack_log_callback(9)smack_log(9)smk_insert_entry(9)smk_find_entry(9)smk_parse_label_len(9)smk_parse_smack(9)smk_netlbl_mls(9)smack_populate_secattr(9)smk_import_entry(9)smk_import_valid_label(9)smack_from_secid(9)smack_privileged_cred(9)smack_privileged(9)
like, go read all of them, iykyk π
mwah, that's the page!! this gem lives over in ./security/smack and it's dated October 2026 β so yeah, she's from the future and she's still serving π
π«Άβ¨
π¦ 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