Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\apparmor\file.c Create Date:2022-07-28 19:54:01
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:ased on selinux's flush_unauthorized_files

Proto:void aa_inherit_files(const struct cred *cred, struct files_struct *files)

Type:void

Parameter:

TypeParameterName
const struct cred *cred
struct files_struct *files
698  label = aa_get_newest_cred_label - obtain the newest label on a cred*@cred: cred to obtain label from (NOT NULL)* Returns: newest version of confining label
699  struct file * devnull = NULL
702  revalidate_tty(label)
705  n = iterate_fd(files, 0, match_file, label)
706  If Not n Then Go to out
709  devnull = dentry_open( & aa_null, O_RDWR, cred)
710  If IS_ERR(devnull) Then devnull = NULL
713  Do
714  replace_fd(n - 1, devnull, 0)
715  When (n = iterate_fd(files, n, match_file, label)) != 0 cycle
716  If devnull Then fput(devnull)
718  out :
719  aa_put_label(label)
Caller
NameDescribe
apparmor_bprm_committing_credsapparmor_bprm_committing_creds - do task cleanup on committing new creds*@bprm: binprm for the exec (NOT NULL)