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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <AANLkTim9XWU-Qn5OT1J8H2j4kajMLL_GTQQ4_N296ueJ@mail.gmail.com>
Date:	Tue, 16 Nov 2010 01:44:18 +0300
From:	Alexey Zaytsev <alexey.zaytsev@...il.com>
To:	Eric Paris <eparis@...hat.com>
Cc:	Tvrtko Ursulin <tvrtko.ursulin@...hos.com>,
	linux-fsdevel@...r.kernel.org,
	"stefan@...ttcher.org" <stefan@...ttcher.org>,
	linux-kernel@...r.kernel.org, Al Viro <viro@...iv.linux.org.uk>
Subject: Re: A possible flaw in the fsnotify design.

On Tue, Nov 16, 2010 at 01:11, Eric Paris <eparis@...hat.com> wrote:
> On Tue, 2010-11-16 at 01:05 +0300, Alexey Zaytsev wrote:
>> Just some thoughts.
>>
>> Consider the situation: Files A and B both point to the same inode.
>> File A is being watched, but the user won't get notifications if B is
>> modified.
>
> That's not true.  Users watch inodes, not files (this is true for both
> inotify and fanotify).  Give it a try, it works.
>

debian-i386:~/tmp# touch a
debian-i386:~/tmp# ../fanotify a &
debian-i386:~/tmp# link a b
debian-i386:~/tmp# ls -li
total 0
3433 -rw-r--r-- 2 root root 0 Nov 15 22:37 a
3433 -rw-r--r-- 2 root root 0 Nov 15 22:37 b
debian-i386:~/tmp# echo 123 > b
/root/tmp/b: pid=2143 mask = 20 open
/root/tmp/b: pid=2143 mask = a modify 0 - 4 close(writable)  0 - 4

Am I doing something wrong? Same thing happens if I watch the mount point.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ