All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel J Walsh <dwalsh@redhat.com>
To: Stephen Smalley <sds@tycho.nsa.gov>
Cc: Ramon de Carvalho Valle <rcvalle@linux.vnet.ibm.com>,
	SELinux@tycho.nsa.gov
Subject: Re: SELinux mixed/virtualisation policy
Date: Wed, 13 Apr 2011 10:01:35 -0400	[thread overview]
Message-ID: <4DA5ACBF.7020704@redhat.com> (raw)
In-Reply-To: <1302702685.16451.25.camel@moss-pluto>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 04/13/2011 09:51 AM, Stephen Smalley wrote:
> On Wed, 2011-04-13 at 10:03 -0300, Ramon de Carvalho Valle wrote:
>> On 04/13/2011 09:19 AM, Stephen Smalley wrote:
>>> At present, virtd_t (i.e. libvirtd) is given many (all?) MLS overrides,
>>> which is unsurprising since it is expected to create and manage VMs at
>>> any level.  But qemu_t (i.e. the qemu process representing the
>>> individual VM) is not given such MLS overrides, nor should it, as that
>>> would allow to escape the confines of its level/range.
>> Actually, processes representing virtual machine environments--when
>> initiated by libvirt--execute with svirt_t and not qemu_t, which also
>> belongs to virt_domain type attribute. So why the virt_domain rules
>> could not be moved to the virtualisation sensitivities?
> 
> The same is true for svirt_t - if you look at the policy, you'll see
> that it interacts with various host processes and accesses various host
> files.  You can't push all of those into your new sensitivities, and
> thus the end result will be that you'll have to allow interactions
> between the "regular" sensitivities and the "virtualization"
> sensitivities, thereby adding more exceptions to the MLS constraints.
> 
>>> I can't quite see how your approach is cleaner than just using separate
>>> categories.  Same effect - by allocating a dedicated category to the VMs
>>> and another to the host, you end up with incomparable levels and thus
>>> will achieve automatic isolation except where explicitly overridden
>>> using the type attributes for MLS overrides.  Adding another
>>> incomparable set of sensitivities puts us outside the scope of any
>>> evaluated or even published security model.
>> How dynamic labeling is supposed to work with this approach? We will
>> need a standard set of categories defined to libvirt use.
> 
> Yes, you just need to standardize some allocation for libvirt, which
> realistically ought to be done anyway, since we already have other users
> of categories like sandbox.
> 
>>> Now something that has been suggested in the past would be adding
>>> another level/range component to the security context for use by a
>>> Biba-like integrity model.  That might be interesting, but would
>>> obviously require quite a few changes on both the kernel and userland
>>> side.  It would also require resolving the unfortunate ambiguity in the
>>> current security context format.
>> Please, correct if I am wrong, but from what I understand adding another
>> level and range component will just add another level of hierarchy for
>> multiple set of sensitivities and categories (i.e.
>> s0-s15:s0-s15:c0.c1023 or even s0-s15:c0.c1023:s0-s15:c0.c1023). So the
>> virtualised sensitivities should be below or above the standard
>> sensitivities in this new level and range component?
> 
> Having another level/range component (or more generally, an extensible
> list of level/range components) would more easily delineate multiple
> uses of the level/range for different purposes.  So you could have
> simultaneous MLS+libvirt dynamic labeling without needing to worry about
> allocation of categories between them.  Or you could have simultaneous
> MLS+Biba.  Or all three (if extensible).
>  

I will open a bugzilla with libvirt to allow the admin to specify a
sensitivity and a range of MCS labels to randomly choose between.  This
might be necessary for an other use case that suddenly seems to be
picking up steam, labeled NFS.  If Labeled NFS happens we need a way to
make sure two libvirt instances do not choose the same Categories, to
start virtual machines.


Sandbox MCS and SVirt MCS and any other MCS (Coming soon) should still
be isolated by type enforcement rules.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAk2lrL8ACgkQrlYvE4MpobPTaQCfSiOElDU7Ncpr3RahZIAMqnxG
N5IAnjwV7vn+FRysCBY6KWV72KneHvj2
=fDFD
-----END PGP SIGNATURE-----

--
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:[~2011-04-13 14:01 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-10 17:12 SELinux mixed/virtualisation policy Ramon de Carvalho Valle
2011-04-11 13:40 ` Stephen Smalley
2011-04-11 15:24   ` Daniel J Walsh
2011-04-11 16:33     ` Stephen Smalley
2011-04-11 17:14       ` Ramon de Carvalho Valle
2011-04-11 17:59       ` Daniel J Walsh
2011-04-11 20:44         ` chanson
2011-04-11 21:03           ` Daniel J Walsh
2011-04-12 12:50         ` Stephen Smalley
2011-04-13 10:24           ` Ramon de Carvalho Valle
2011-04-13 12:19             ` Stephen Smalley
2011-04-13 13:03               ` Ramon de Carvalho Valle
2011-04-13 13:34                 ` Russell Coker
2011-04-13 13:51                 ` Stephen Smalley
2011-04-13 14:01                   ` Daniel J Walsh [this message]
2011-04-13 18:33                     ` Ramon de Carvalho Valle
2011-04-13 18:32                   ` Ramon de Carvalho Valle
2011-04-13 19:09                     ` Daniel J Walsh
2011-04-11 14:20 ` Russell Coker
2011-04-11 17:26   ` Ramon de Carvalho Valle

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=4DA5ACBF.7020704@redhat.com \
    --to=dwalsh@redhat.com \
    --cc=SELinux@tycho.nsa.gov \
    --cc=rcvalle@linux.vnet.ibm.com \
    --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 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.