diff options
author | Konstantin Meskhidze <konstantin.meskhidze@huawei.com> | 2023-10-26 09:47:44 +0800 |
---|---|---|
committer | Mickaël Salaün <mic@digikod.net> | 2023-10-26 21:07:13 +0200 |
commit | 0e7410112964168a65578002269ae3b80b207936 (patch) | |
tree | aedfb6183ad6496f279b01cd5662c43f1921676a /security/landlock/ruleset.h | |
parent | 6146b6141770206792d0e1155794cc48697c7985 (diff) | |
download | linux-0e7410112964168a65578002269ae3b80b207936.tar.gz linux-0e7410112964168a65578002269ae3b80b207936.tar.bz2 linux-0e7410112964168a65578002269ae3b80b207936.zip |
landlock: Move and rename layer helpers
Move and rename landlock_unmask_layers() and landlock_init_layer_masks()
helpers to ruleset.c to share them with Landlock network implementation
in following commits.
Signed-off-by: Konstantin Meskhidze <konstantin.meskhidze@huawei.com>
Link: https://lore.kernel.org/r/20231026014751.414649-6-konstantin.meskhidze@huawei.com
Signed-off-by: Mickaël Salaün <mic@digikod.net>
Diffstat (limited to 'security/landlock/ruleset.h')
-rw-r--r-- | security/landlock/ruleset.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/security/landlock/ruleset.h b/security/landlock/ruleset.h index 9e04c666b23c..760e049f3e0a 100644 --- a/security/landlock/ruleset.h +++ b/security/landlock/ruleset.h @@ -267,4 +267,14 @@ landlock_get_fs_access_mask(const struct landlock_ruleset *const ruleset, LANDLOCK_ACCESS_FS_INITIALLY_DENIED; } +bool landlock_unmask_layers( + const struct landlock_rule *const rule, + const access_mask_t access_request, + layer_mask_t (*const layer_masks)[LANDLOCK_NUM_ACCESS_FS]); + +access_mask_t landlock_init_layer_masks( + const struct landlock_ruleset *const domain, + const access_mask_t access_request, + layer_mask_t (*const layer_masks)[LANDLOCK_NUM_ACCESS_FS]); + #endif /* _SECURITY_LANDLOCK_RULESET_H */ |