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: <20070522083826.GD4728@in.ibm.com>
Date:	Tue, 22 May 2007 14:08:26 +0530
From:	Bharata B Rao <bharata@...ux.vnet.ibm.com>
To:	Jan Engelhardt <jengelh@...ux01.gwdg.de>
Cc:	Shaya Potter <spotter@...columbia.edu>,
	linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org,
	Jan Blunck <j.blunck@...harburg.de>
Subject: Re: [RFC][PATCH 10/14] In-kernel file copy between union mounted filesystems

On Tue, May 22, 2007 at 08:25:16AM +0200, Jan Engelhardt wrote:
> 
> On May 22 2007 08:43, Bharata B Rao wrote:
> >On Fri, May 18, 2007 at 09:47:31AM -0400, Shaya Potter wrote:
> >> Bharata B Rao wrote:
> >> 
> >> >
> >> >Not really. This is called during copyup of a file residing in a lower
> >> >layer. And that is done only for regular files.
> >> 
> >> That is broken.
> >
> >But it only breaks the semantics (in other cases we allow writes only to the
> >top layer files). So the question is why do we have to copy up the device
> >node ? What difference it makes to writing to the device itself ?
> 
> Because `chmod 666 blockdevnode` is not the same as writing
> to the device itself?

What if that chmod is applied on the lower level device node ? This is what
we do currently, even for regular files. Copyup happens only when the file
is opened for writing.

Let me rephrase my earlier question:

In case of regular files, when we copyup a file, we are actually preventing
any writes to the lower layers (which we have designated as read only).

Applying the same logic to devices, what do we achieve by copying them up ?
How does it matter if we write to the device through a node in the upper
layer or in the lower layer. Both the writes eventually do the same thing.

What I am trying to understand is, if the need for copyup is purely a matter
of conforming to semantics (of not allowing writes to the lower layers in
case of union mount) or do we achieve anything else by doing a device
copyup ? Are there any cases where copying up of device nodes are absolutely
essential for sane behaviour ?

Regards,
Bharata.
-
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