All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Smalley <sds@tycho.nsa.gov>
To: Jason Johnson <jason.johnson.081@gmail.com>
Cc: KaiGai Kohei <kaigai@ak.jp.nec.com>, SE-Linux <selinux@tycho.nsa.gov>
Subject: Re: Possible bug with fd class?
Date: Wed, 17 Jun 2009 15:17:44 -0400	[thread overview]
Message-ID: <1245266264.3033.64.camel@localhost.localdomain> (raw)
In-Reply-To: <1245266012.3033.63.camel@localhost.localdomain>

On Wed, 2009-06-17 at 15:13 -0400, Stephen Smalley wrote:
> On Wed, 2009-06-17 at 20:28 +0200, Jason Johnson wrote:
> > On Wed, Jun 17, 2009 at 2:26 PM, Stephen Smalley<sds@tycho.nsa.gov> wrote:
> > >> >
> > > No, that would show up as a separate AVC, and would
> > > reference /selinux/null rather than /dev/null.
> > >
> > > Some entries in file_contexts are for other distributions and may not
> > > apply to your particular filesystem.  That's ok - it doesn't do any
> > > harm.
> > 
> > Oh, I knew that entry wouldn't do anything.  I just meant that is the
> > closest connection I can see from syslog to logrotate.
> > 
> > So is this entry a bug:
> > 
> > kernel: [1298522.518701] type=1400 audit(1245126419.780:229): avc:
> > denied  { use } for  pid=29944 comm="syslog-ng" path="/dev/null"
> > dev=tmpfs ino=634 scontext=system_u:system_r:syslogd_t:s0
> > tcontext=system_u:system_r:logrotate_t:s0-s0:c0.c1023 tclass=fd
> > 
> > ?
> 
> This just means that logrotate invoked syslog-ng while holding open a
> descriptor to /dev/null.  Nothing more.

And I assume that's intentional, e.g. it is redirecting stdin, stdout,
stderr to /dev/null when invoking it.  So you can just allow it in your
policy.

-- 
Stephen Smalley
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.

  reply	other threads:[~2009-06-17 19:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-16  4:48 Possible bug with fd class? Jason Johnson
2009-06-16  5:18 ` KaiGai Kohei
2009-06-16 17:31   ` Jason Johnson
2009-06-16 20:01     ` Stephen Smalley
2009-06-16 21:13       ` Jason Johnson
2009-06-17 12:26         ` Stephen Smalley
2009-06-17 18:28           ` Jason Johnson
2009-06-17 19:13             ` Stephen Smalley
2009-06-17 19:17               ` Stephen Smalley [this message]
     [not found]               ` <aa22f0200906172153n2c67abcj1309a76208c5b96e@mail.gmail.com>
2009-06-18 12:48                 ` Stephen Smalley

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=1245266264.3033.64.camel@localhost.localdomain \
    --to=sds@tycho.nsa.gov \
    --cc=jason.johnson.081@gmail.com \
    --cc=kaigai@ak.jp.nec.com \
    --cc=selinux@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.