set_create_files_as(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 set_create_files_as(9) β€” Kernel API Manual energy 🌸

okay bestie, welcome to the Kernel API Manual page for set_create_files_as(9) β€” this one is short, sweet, and lowkey iconic. πŸ’…


✨ NAME ✨

set_create_files_as β€” Set the LSM file create context in a set of credentials

πŸŽ€ SYNOPSIS πŸŽ€

int set_create_files_as (struct cred *new , struct inode *inode );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • new β€” The credentials to alter.
  • inode β€” The inode to take the context from.

πŸ’– DESCRIPTION πŸ’–

Okay so here’s the vibe: this changes the LSM file creation context in a set of credentials so it’s the same as the object context of the specified inode. The whole point? So that the new inodes have the same MAC context as that inode. No cap, that’s the whole little glow-up. ✨

🌈 SEE ALSO 🌈

Kernel file ./kernel/cred.c: __put_cred(9), get_task_cred(9), prepare_creds(9), commit_creds(9), abort_creds(9), cred_fscmp(9), prepare_kernel_cred(9), set_security_override(9).


that’s the whole page, bestie! Signing off from source/version ./kernel, dated October 2026, with set_create_files_as(9) energy. Mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from