From: James Morris <jmorris@namei.org>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Jens Axboe <jens.axboe@oracle.com>, Ingo Molnar <mingo@elte.hu>,
linux-kernel@vger.kernel.org, Stephen Smalley <sds@tycho.nsa.gov>
Subject: Re: [PATCH][RFC] security: revalidate rw permissions for sys_splice and sys_vmsplice
Date: Wed, 30 May 2007 14:29:09 -0400 (EDT) [thread overview]
Message-ID: <Line.LNX.4.64.0705301425570.17724@d.namei> (raw)
In-Reply-To: <20070530111743.e638c841.akpm@linux-foundation.org>
On Wed, 30 May 2007, Andrew Morton wrote:
> On Wed, 30 May 2007 09:15:01 +0200
> Jens Axboe <jens.axboe@oracle.com> wrote:
>
> > On Tue, May 29 2007, James Morris wrote:
> > > Revalidate read/write permissions for splice(2) and vmslice(2), in case
> > > security policy has changed since the files were opened.
> >
> > I guess it was inevitably going to happen :-)
> >
> > Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
> >
>
> Probably acked-by was more appropriate.
>
> James, is this considered needed-for-2.6.22?
No, it's tightening things up. We don't have full revocation in any case,
and the primary security check is performed on open.
> > + ret = security_file_permission(out, MAY_WRITE);
> > + if (unlikely(ret < 0))
> > + return ret;
>
>
> ot: all the unlikely()s are irksome. I wonder if there was some way of
> doing this in security_file_permission() instead. eg:
This is the only place where we do this -- it's to remain consistent with
the surrounding splice code, which does this for other checks. Given that
it's calling out to a typically non-trivial security module, it may be
better to remove the unlikelys here.
- James
--
James Morris
<jmorris@namei.org>
prev parent reply other threads:[~2007-05-30 18:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-29 20:22 James Morris
2007-05-30 7:15 ` Jens Axboe
2007-05-30 18:17 ` Andrew Morton
2007-05-30 18:29 ` James Morris [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Line.LNX.4.64.0705301425570.17724@d.namei \
--to=jmorris@namei.org \
--cc=akpm@linux-foundation.org \
--cc=jens.axboe@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=sds@tycho.nsa.gov \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®