]> www.infradead.org Git - users/hch/configfs.git/commit
landlock: Refactor filesystem access mask management
authorMickaël Salaün <mic@digikod.net>
Sat, 9 Nov 2024 11:08:54 +0000 (12:08 +0100)
committerMickaël Salaün <mic@digikod.net>
Sat, 9 Nov 2024 18:52:10 +0000 (19:52 +0100)
commit0c0effb07f7d662af3e6f74da4d34241e412029b
treeb43586ba60a21a34658f4d825edd3722d0736501
parent53b9d789df983790015ef04b0283ac5a33917cad
landlock: Refactor filesystem access mask management

Replace get_raw_handled_fs_accesses() with a generic
landlock_union_access_masks(), and replace get_fs_domain() with a
generic landlock_get_applicable_domain().  These helpers will also be
useful for other types of access.

Cc: Mikhail Ivanov <ivanov.mikhail1@huawei-partners.com>
Reviewed-by: Günther Noack <gnoack@google.com>
Link: https://lore.kernel.org/r/20241109110856.222842-2-mic@digikod.net
[mic: Slightly improve doc as suggested by Günther]
Signed-off-by: Mickaël Salaün <mic@digikod.net>
security/landlock/fs.c
security/landlock/ruleset.h
security/landlock/syscalls.c