-
Notifications
You must be signed in to change notification settings - Fork 10
Description
Hi guys!
I am very new to landlock.
As far as I understand, the one can
allow the particular actions based on
a file path, but what I was looking
for, should also include permission
check.
That is, would it make sense to add
the actions like:
LANDLOCK_ACCESS_FS_WRITE_FILE_USER
LANDLOCK_ACCESS_FS_WRITE_FILE_GROUP
LANDLOCK_ACCESS_FS_WRITE_FILE_OTHER
so that I can eg allow the access only by
"Other" permission bits, but keep User and
Group denied for files in the specified dir?
More precisely, if I only use
LANDLOCK_ACCESS_FS_WRITE_FILE_OTHER
then User and Group checks are not enough
to grant the permission, but are only enough
to reject the permission.
In that semantic,
(LANDLOCK_ACCESS_FS_WRITE_FILE_USER |
LANDLOCK_ACCESS_FS_WRITE_FILE_GROUP |
LANDLOCK_ACCESS_FS_WRITE_FILE_OTHER) ==
LANDLOCK_ACCESS_FS_WRITE_FILE
I.e. specifying all 3 is similar to what
LANDLOCK_ACCESS_FS_WRITE_FILE does
right now. So basically its just a more
fine-grained control.
What do you think? Does something like this
make a sense?