Re: [patch] kernel sysfs events layer

Kay Sievers
2004-09-15T21:14:55Z

On Wed, Sep 15, 2004 at 01:56:43PM -0700, Tim Hockin wrote:
> On Wed, Sep 15, 2004 at 04:49:18PM -0400, Robert Love wrote:
> > On Wed, 2004-09-15 at 13:47 -0700, Tim Hockin wrote:
> >
> > > Are you not sending it with some specific device as the source? Or is it
> > > just coming from some abstract root kobject?
> >
> > It comes the the physical device.
> >
> > Is there really a specific issue that you are seeing?
>
> Well, two.
>
> 1) If you send me an event "/dev/hda3 mounted", but it was for some other
> namespace, you just leaked potentially useful information.

You can listen only as root!
All information is already in /proc/mounts.

> I'm no security expert, but that seems to me to be a gratuitous leak.

I don't aggree on the second part :)

> Maybe it's just another example of why namespaces need to go away.
>
> 2) If you send me an event "/dev/hda3 mounted" do I also get an event when
> I loopback mount /tmp/rh9.0-1.iso or when I bind mount /foo to /bar or
> when I mount server:/export/home on /home?

You get an event if fs-code claims/relases a genhd. It's a claim/release
event to be more precise. Only the first mount will emit a event and the
last umount.

thaks,
Kay