All of lore.kernel.org
 help / color / mirror / Atom feed
From: sven.vermeulen@siphos.be (Sven Vermeulen)
To: refpolicy@oss.tresys.com
Subject: [refpolicy] [PATCH 1/1] Allow mount to work on all file locations
Date: Mon, 26 Dec 2011 12:05:13 +0100	[thread overview]
Message-ID: <20111226110513.GA29779@siphos.be> (raw)
In-Reply-To: <4E68F77C.4030109@tresys.com>

On Thu, Sep 08, 2011 at 01:12:28PM -0400, Christopher J. PeBenito wrote:
> > It is indeed with a context mount that we encountered the issue (see
> > https://bugs.gentoo.org/show_bug.cgi?id=373673#c4)
> >
> > It can be easily reproduced even on non-NFS:
> >
> > build log # mount -t tmpfs -o context=system_u:object_r:portage_ebuild_t tmpfs /mnt
> > mount: block device tmpfs is write-protected, mounting read-only
> > mount: cannot mount block device tmpfs read-only
> >
> > build log # cat avc.log
> > Sep  7 21:22:17 build kernel: [ 3814.028379] type=1400
> > audit(1315423337.025:106): avc:  denied  { relabelfrom } for  pid=3736
> > comm="mount" scontext=root:sysadm_r:mount_t
> > tcontext=system_u:object_r:portage_ebuild_t tclass=filesystem
> > Sep  7 21:22:17 build kernel: [ 3814.036543] type=1400
> > audit(1315423337.034:107): avc:  denied  { relabelfrom } for  pid=3736
> > comm="mount" scontext=root:sysadm_r:mount_t
> > tcontext=system_u:object_r:portage_ebuild_t tclass=filesystem
> >
> > With the relabelfrom privilege the mount works as expected.
> 
> This looks like a bug.  I'd expect the relabelfrom tcontext to be tmpfs_t.  I've asked Eric Paris to look into this.

Any feedback on this?

Wkr,
	Sven Vermeulen

  reply	other threads:[~2011-12-26 11:05 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-04 12:21 [refpolicy] [PATCH 1/1] Allow mount to work on all file locations Sven Vermeulen
2011-09-06 18:36 ` Christopher J. PeBenito
2011-09-07 19:23   ` Sven Vermeulen
2011-09-08 17:12     ` Christopher J. PeBenito
2011-12-26 11:05       ` Sven Vermeulen [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-07-20 17:18 Sven Vermeulen

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=20111226110513.GA29779@siphos.be \
    --to=sven.vermeulen@siphos.be \
    --cc=refpolicy@oss.tresys.com \
    /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.