diff options
Diffstat (limited to 'include/linux/lsm_hooks.h')
-rw-r--r-- | include/linux/lsm_hooks.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/linux/lsm_hooks.h b/include/linux/lsm_hooks.h index a240a3fc5fc4..f7e55d0d2672 100644 --- a/include/linux/lsm_hooks.h +++ b/include/linux/lsm_hooks.h | |||
@@ -445,6 +445,15 @@ | |||
445 | * to abort the copy up. Note that the caller is responsible for reading | 445 | * to abort the copy up. Note that the caller is responsible for reading |
446 | * and writing the xattrs as this hook is merely a filter. | 446 | * and writing the xattrs as this hook is merely a filter. |
447 | * | 447 | * |
448 | * Security hooks for kernfs node operations | ||
449 | * | ||
450 | * @kernfs_init_security: | ||
451 | * Initialize the security context of a newly created kernfs node based | ||
452 | * on its own and its parent's attributes. | ||
453 | * | ||
454 | * @kn_dir the parent kernfs node | ||
455 | * @kn the new child kernfs node | ||
456 | * | ||
448 | * Security hooks for file operations | 457 | * Security hooks for file operations |
449 | * | 458 | * |
450 | * @file_permission: | 459 | * @file_permission: |
@@ -1570,6 +1579,9 @@ union security_list_options { | |||
1570 | int (*inode_copy_up)(struct dentry *src, struct cred **new); | 1579 | int (*inode_copy_up)(struct dentry *src, struct cred **new); |
1571 | int (*inode_copy_up_xattr)(const char *name); | 1580 | int (*inode_copy_up_xattr)(const char *name); |
1572 | 1581 | ||
1582 | int (*kernfs_init_security)(struct kernfs_node *kn_dir, | ||
1583 | struct kernfs_node *kn); | ||
1584 | |||
1573 | int (*file_permission)(struct file *file, int mask); | 1585 | int (*file_permission)(struct file *file, int mask); |
1574 | int (*file_alloc_security)(struct file *file); | 1586 | int (*file_alloc_security)(struct file *file); |
1575 | void (*file_free_security)(struct file *file); | 1587 | void (*file_free_security)(struct file *file); |
@@ -1871,6 +1883,7 @@ struct security_hook_heads { | |||
1871 | struct hlist_head inode_getsecid; | 1883 | struct hlist_head inode_getsecid; |
1872 | struct hlist_head inode_copy_up; | 1884 | struct hlist_head inode_copy_up; |
1873 | struct hlist_head inode_copy_up_xattr; | 1885 | struct hlist_head inode_copy_up_xattr; |
1886 | struct hlist_head kernfs_init_security; | ||
1874 | struct hlist_head file_permission; | 1887 | struct hlist_head file_permission; |
1875 | struct hlist_head file_alloc_security; | 1888 | struct hlist_head file_alloc_security; |
1876 | struct hlist_head file_free_security; | 1889 | struct hlist_head file_free_security; |