Re: [malware-list] [RFC 3/11] fanotify: fscking all notify, system wide file access notification

Previous thread: [RFC 2/11] fsnotify: pass a file instead of an inode to open modify and read by Eric Paris on Friday, September 26, 2008 - 2:18 pm. (2 messages)

Next thread: [RFC 1/11] filesystem notification: create fs/notify to contain all fs notification by Eric Paris on Friday, September 26, 2008 - 2:18 pm. (1 message)
From: Eric Paris
Date: Friday, September 26, 2008 - 2:18 pm

fanotify: fscking all notify, system wide file access notification

From: Eric Paris <eparis@redhat.com>

A new system wide file access notification system.

Signed-off-by: Eric Paris <eparis@redhat.com>
---

 fs/notify/Kconfig             |   14 ++
 fs/notify/Makefile            |    2 
 fs/notify/fanotify.c          |  117 ++++++++++++++++++++
 fs/notify/fanotify.h          |   87 +++++++++++++++
 fs/notify/group.c             |  153 ++++++++++++++++++++++++++
 fs/notify/group_user.c        |  156 +++++++++++++++++++++++++++
 fs/notify/notification.c      |  167 +++++++++++++++++++++++++++++
 fs/notify/notification_user.c |  239 +++++++++++++++++++++++++++++++++++++++++
 include/linux/fanotify.h      |   53 +++++++++
 include/linux/fsnotify.h      |   14 ++
 include/linux/sched.h         |    1 
 11 files changed, 999 insertions(+), 4 deletions(-)
 create mode 100644 fs/notify/fanotify.c
 create mode 100644 fs/notify/fanotify.h
 create mode 100644 fs/notify/group.c
 create mode 100644 fs/notify/group_user.c
 create mode 100644 fs/notify/notification.c
 create mode 100644 fs/notify/notification_user.c
 create mode 100644 include/linux/fanotify.h


diff --git a/fs/notify/Kconfig b/fs/notify/Kconfig
index 23415de..97cc832 100644
--- a/fs/notify/Kconfig
+++ b/fs/notify/Kconfig
@@ -36,3 +36,17 @@ config INOTIFY_USER
 	  For more information, see <file:Documentation/filesystems/inotify.txt>
 
 	  If unsure, say Y.
+
+config FANOTIFY
+        bool "Filesystem wide access notification"
+        select SECURITY
+        default y
+        ---help---
+           Say Y here to enable fanotify suport.  fanotify is a system wide
+           file access notification interface.  Events are read from from a
+           single open fd and in doing so a fd is created in the reading process
+           which points to the same data as the one on which the event occured.
+
+           For more information, see <file:Documentation/filesystems/fanotify.txt>
+
+           If ...
From: Greg KH
Date: Friday, September 26, 2008 - 3:17 pm

Userspace api changes/additions need to also cc: the
linux-api@vger.kernel.org list now.

thanks,

greg k-h
--

From: Greg KH
Date: Friday, September 26, 2008 - 3:21 pm

Those are some pretty generic global function names (get_event?).
Please add a fanotify_ to the front of them to help developers


Again with the generic global symbol names.

thanks,

greg k-h
--

Previous thread: [RFC 2/11] fsnotify: pass a file instead of an inode to open modify and read by Eric Paris on Friday, September 26, 2008 - 2:18 pm. (2 messages)

Next thread: [RFC 1/11] filesystem notification: create fs/notify to contain all fs notification by Eric Paris on Friday, September 26, 2008 - 2:18 pm. (1 message)