Skip to content

Commit

Permalink
fs/ioctl: Add a comment to keep the logic in sync with LSM policies
Browse files Browse the repository at this point in the history
Landlock's IOCTL support needs to partially replicate the list of
IOCTLs from do_vfs_ioctl().  The list of commands implemented in
do_vfs_ioctl() should be kept in sync with Landlock's IOCTL policies.

Suggested-by: Paul Moore <[email protected]>
Suggested-by: Mickaël Salaün <[email protected]>
Signed-off-by: Günther Noack <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mickaël Salaün <[email protected]>
  • Loading branch information
gnoack authored and l0kod committed May 13, 2024
1 parent 943aa81 commit d1654fd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions fs/ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,9 @@ static int ioctl_get_fs_sysfs_path(struct file *file, void __user *argp)
*
* When you add any new common ioctls to the switches above and below,
* please ensure they have compatible arguments in compat mode.
*
* The LSM mailing list should also be notified of any command additions or
* changes, as specific LSMs may be affected.
*/
static int do_vfs_ioctl(struct file *filp, unsigned int fd,
unsigned int cmd, unsigned long arg)
Expand Down

0 comments on commit d1654fd

Please sign in to comment.