tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: vaccess() and ntfs_access() and...



On Wed, Apr 22, 2009 at 02:30:35AM +0300, Elad Efrat wrote:
 > It looks like vaccess() in and ntfs_access() are mostly the same,
 > except for:
 > 
 >   1. ntfs_access() disallows writing to a read-only file-system unless
 >      writing to a socket, fifo, or a block device
 > 
 >   2. vaccess() requires at least one exec bit to allow execution (for
 >      the superuser)
 > 
 > Are we interested in uniting them, ie., make vaccess() enforce #1 and
 > ntfs care about #2? (so we can just call vaccess() from ntfs_access()
 > like all other file-systems)

I don't know. But:

 > Speaking of all other file-systems, is there a reason some don't care
 > if the file-system is read-only and some do? and among those who do,
 > some care about the vnode type (VREG, VDIR, ...) and some don't?

Accumulation of entropy. If you feel like performing a net input of
energy, it would be a good thing, but the first step has to be to wade
through all of them (and the call sites, etc.) to figure out what the
right set of checks is.

 > and that some use the file-system node (FSNAME_VTOI(vp)) to get the
 > uid/gid etc., and some VOP_GETATTR()?

Given layers I believe the former are wrong, but I'd want a second or
third opinion before taking any steps.

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index