lkml.org 
[lkml]   [2000]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectOpen by inode (was Re: your mail)

>On Sat, Mar 18, 2000 at 02:45:42PM -0400, Horst von Brand wrote:
>> Jamie Lokier <lfs@tantalophile.demon.co.uk> said:
>
>> > I wrote and posted an open-by-inode extension to ext2 about a year ago.
>> > You simply open <fs>/.inode/<number>. But nobody was interested, so I
>> > guess there isn't much demand after all.

>> Demand is (or should be) _strongly_ negative. Open by inode allows to
>> completely bypass placing files in non-x directories, thus breaking
>> security big time.

>If you want to stop people accessing *inodes*, the appropriate permissions
>should be set for the inode. Permissions on directories AFAIK only control
>access to the contents of the directory - which are just (name, inum) pairs.
>The fact that there's no standardised API for open-by-inode isn't necessarily
>a feature. And anyway, even if Jamie's feature got integrated, I'm sure it
>would be off by default.

We have implemented open-by-inode-number as a kernel module for 2.2.*.
It approximately follows the "[major:minor:inode]" syntax in the /proc
psuedo-filesystem. I encourage anyone else implementing a similar
mechanism to follow the same syntax.

I mention our implementation only as a point of interest.
This is *not* a general purpose mechanism.
There is no reason to provide this as a kernel feature.

Most filesystems get *really nervous* when you access an inconsistent inode,
and some even become unhappy if you merely reference a inode with a zero
count. We only use it with devices that are marked unwritable, preferably
with a hardware mechanism or loopback mounted.

Needless to say, any mechanism that so readily cause kernel corruption is
available only to 'root', so the file security issue never even needs to be
considered.

Donald Becker
Scyld Computing Corporation, becker@scyld.com


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:57    [W:0.084 / U:0.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site