lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Mon,  6 Jun 2022 23:42:40 +0100
From:   Oliver Ford <ojford@...il.com>
To:     linux-fsdevel@...r.kernel.org, jack@...e.cz, amir73il@...il.com
Cc:     linux-kernel@...r.kernel.org, ojford@...il.com
Subject: [PATCH 0/1] fs: inotify: Add full paths option to inotify

Adds an option to return the full path in inotify events. Currently, user space has to keep track of watch descriptors and paths, mapping the descriptor returned when reading inotify events to the path. Adding an option to return the full path simplifies user space code.

The patch adds a flag, IN_FULL_PATHS, to the available mask in inotify_add_watch. When set, the full path is returned when events are added to the watch queue and a path is available. For the event IN_MOVE_SELF, a check is performed that the user has access to the new path. This prevents exposing the names of directories if, for example, root moves "/home/dmr/watched" to "/root/top_secret/watched". In that case, the watch is removed and a Permission Denied error is returned. For the IN_DELETE_SELF/IN_IGNORED pair, no path is returned.

Oliver Ford (1):
  fs: inotify: Add full paths option to inotify

 fs/notify/inotify/inotify_fsnotify.c | 55 ++++++++++++++++++++++------
 fs/notify/inotify/inotify_user.c     | 19 +++++++++-
 include/linux/inotify.h              |  2 +-
 include/uapi/linux/inotify.h         |  1 +
 4 files changed, 63 insertions(+), 14 deletions(-)

-- 
2.35.1

Powered by blists - more mailing lists