Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Theodore Tso
On Thu, Nov 22, 2007 at 07:56:20PM +, Alan Cox wrote: > > probably principle of least privilege; the location on physical media > > for a file is clearly something internal to the OS, and non-trusted > > users normally don't have any business knowing that. > > FIBMAP isn't correctly locked

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Alan Cox
> probably principle of least privilege; the location on physical media > for a file is clearly something internal to the OS, and non-trusted > users normally don't have any business knowing that. FIBMAP isn't correctly locked against misuse, and that requires FIBMAP is safe against truncate and

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Alan Cox
On Thu, 22 Nov 2007 19:17:14 +0100 Jan Kara <[EMAIL PROTECTED]> wrote: > Hi, > > I guess subject says it all - why is FIBMAP ioctl restricted only to > root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any > special capabilities so we are inconsistent here too... > Would

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Olivier Galibert
Original thread btw: http://www.ussg.indiana.edu/hypermail/linux/kernel/9907.0/0132.html OG. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Olivier Galibert
On Thu, Nov 22, 2007 at 07:17:14PM +0100, Jan Kara wrote: > Hi, > > I guess subject says it all - why is FIBMAP ioctl restricted only to > root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any > special capabilities so we are inconsistent here too... > Would anyone mind

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Arjan van de Ven
On Thu, 22 Nov 2007 19:17:14 +0100 Jan Kara <[EMAIL PROTECTED]> wrote: > Hi, > > I guess subject says it all - why is FIBMAP ioctl restricted only to > root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without > any special capabilities so we are inconsistent here too... > Would

Why is FIBMAP ioctl root only?

2007-11-22 Thread Jan Kara
Hi, I guess subject says it all - why is FIBMAP ioctl restricted only to root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any special capabilities so we are inconsistent here too... Would anyone mind if the check is removed?

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Arjan van de Ven
On Thu, 22 Nov 2007 19:17:14 +0100 Jan Kara [EMAIL PROTECTED] wrote: Hi, I guess subject says it all - why is FIBMAP ioctl restricted only to root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any special capabilities so we are inconsistent here too... Would anyone

Why is FIBMAP ioctl root only?

2007-11-22 Thread Jan Kara
Hi, I guess subject says it all - why is FIBMAP ioctl restricted only to root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any special capabilities so we are inconsistent here too... Would anyone mind if the check is removed?

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Olivier Galibert
Original thread btw: http://www.ussg.indiana.edu/hypermail/linux/kernel/9907.0/0132.html OG. - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Olivier Galibert
On Thu, Nov 22, 2007 at 07:17:14PM +0100, Jan Kara wrote: Hi, I guess subject says it all - why is FIBMAP ioctl restricted only to root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any special capabilities so we are inconsistent here too... Would anyone mind if the

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Alan Cox
On Thu, 22 Nov 2007 19:17:14 +0100 Jan Kara [EMAIL PROTECTED] wrote: Hi, I guess subject says it all - why is FIBMAP ioctl restricted only to root (CAP_SYS_RAWIO)? Corresponding ioctl for XFS is allowed without any special capabilities so we are inconsistent here too... Would anyone

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Alan Cox
probably principle of least privilege; the location on physical media for a file is clearly something internal to the OS, and non-trusted users normally don't have any business knowing that. FIBMAP isn't correctly locked against misuse, and that requires FIBMAP is safe against truncate and

Re: Why is FIBMAP ioctl root only?

2007-11-22 Thread Theodore Tso
On Thu, Nov 22, 2007 at 07:56:20PM +, Alan Cox wrote: probably principle of least privilege; the location on physical media for a file is clearly something internal to the OS, and non-trusted users normally don't have any business knowing that. FIBMAP isn't correctly locked against