Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:smack_init - initialize the smack system* Returns 0 on success, -ENOMEM is there's no memory

Proto:static __init int smack_init(void)

Type:int

Parameter:Nothing

4765  cred = cred
4768  smack_inode_cache = Please use this macro to create slab caches. Simply specify the* name of the structure and maybe some flags that are listed above.* The alignment of the struct determines object alignment. If you* f(inode_smack, 0)
4769  If Not smack_inode_cache Then Return -ENOMEM
4772  smack_rule_cache = Please use this macro to create slab caches. Simply specify the* name of the structure and maybe some flags that are listed above.* The alignment of the struct determines object alignment. If you* f(smack_rule, 0)
4773  If Not smack_rule_cache Then
4774  kmem_cache_destroy(smack_inode_cache)
4775  Return -ENOMEM
4781  tsp = smack_cred(cred)
4782  _task_smack - initialize a task security blob*@tsp: blob to initialize*@task: a pointer to the Smack label for the running task*@forked: a pointer to the Smack label for the forked task
4787  security_add_hooks - Add a modules hooks to the hook lists.*@hooks: the hooks to add*@count: the number of hooks to add*@lsm: the name of the security module* Each LSM has to register its hooks with the infrastructure.
4788  smack_enabled = 1
4790  pr_info("Smack: Initializing.\n")
4792  pr_info("Smack: Netfilter enabled.\n")
4795  pr_info("Smack: IPv6 port labeling enabled.\n")
4798  pr_info("Smack: IPv6 Netfilter enabled.\n")
4802  init_smack_known_list()
4804  Return 0