Thread (64 messages) flat view 64 messages, 11 authors, 2019-10-09

Re: [PATCH 24/32] vfs: syscall: Add fsopen() to prepare for superblock creation [ver #9]

From: Linus Torvalds <torvalds@linux-foundation.org>
Date: 2018-07-12 20:46:06
Also in: linux-fsdevel, lkml

Possibly related (same subject, not in this thread)

On Thu, Jul 12, 2018 at 1:23 PM David Howells [off-list ref] wrote:
It's all very well to say "use file->f_creds".  The problem is this has to be
handed down all the way through the filesystem and down into the block layer
as appropriate to anywhere there's an LSM call, a CAP_* check or a pathwalk -
but there's not currently any way to do that.
.. and the reason is simple: you damn well shouldn't do that.

The unix semantics are that credentials are checked at open time.

If your interface involves checking credentials at write() time, your
interface is garbage shit.

Really.

This is the whole "write() is only for data". If you ever have
credentials mattering at write time, you're doing something wrong.

Really really.

Don't do it.

             Linus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help