Re: [RFC PATCH -v4 13/14] inotify: reimplement inotify using fsnotify
From: Evgeniy Polyakov
Date: Mon Dec 15 2008 - 10:48:19 EST
On Sat, Dec 13, 2008 at 11:44:01AM -0500, Eric Paris (eparis@xxxxxxxxxx) wrote:
> > While you are at it, please update inode_setattr() so that it dropped
> > inotify watches if new permissions do not allow to read data.
>
> Now this isn't so easy.... Do you have suggestions how to do this with
> inotify as it stands today? the vfs needs to know what's hanging on the
> open fd in userspace... Not a bad idea. I'll look, but clearly not a
> core patch....
I could put inotify check into notify_change(), which will check if new
permissions do not allow reading for the users stored in
inode->inotify_watches, each one would be dereferenced to inotify
device, which holds a user context, which added watch object, so it can
be checked the same way generic_permission() works.
--
Evgeniy Polyakov
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/