libvirt/src/security
Daniel P. Berrange b170eb99f5 Add two new security label types
Curently security labels can be of type 'dynamic' or 'static'.
If no security label is given, then 'dynamic' is assumed. The
current code takes advantage of this default, and avoids even
saving <seclabel> elements with type='dynamic' to disk. This
means if you temporarily change security driver, the guests
can all still start.

With the introduction of sVirt to LXC though, there needs to be
a new default of 'none' to allow unconfined LXC containers.

This patch introduces two new security label types

 - default:  the host configuration decides whether to run the
             guest with type 'none' or 'dynamic' at guest start
 - none:     the guest will run unconfined by security policy

The 'none' label type will obviously be undesirable for some
deployments, so a new qemu.conf option allows a host admin to
mandate confined guests. It is also possible to turn off default
confinement

  security_default_confined = 1|0  (default == 1)
  security_require_confined = 1|0  (default == 0)

* src/conf/domain_conf.c, src/conf/domain_conf.h: Add new
  seclabel types
* src/security/security_manager.c, src/security/security_manager.h:
  Set default sec label types
* src/security/security_selinux.c: Handle 'none' seclabel type
* src/qemu/qemu.conf, src/qemu/qemu_conf.c, src/qemu/qemu_conf.h,
  src/qemu/libvirtd_qemu.aug: New security config options
* src/qemu/qemu_driver.c: Tell security driver about default
  config
2012-02-02 17:44:37 -07:00
..
security_apparmor.c apparmor: Mark pid parameter as unused 2012-01-11 12:27:47 +01:00
security_apparmor.h Refactor the security drivers to simplify usage 2011-01-10 18:10:52 +00:00
security_dac.c Change security driver APIs to use virDomainDefPtr instead of virDomainObjPtr 2012-01-11 09:52:18 +00:00
security_dac.h Refactor the security drivers to simplify usage 2011-01-10 18:10:52 +00:00
security_driver.c Refactor the security drivers to simplify usage 2011-01-10 18:10:52 +00:00
security_driver.h Change security driver APIs to use virDomainDefPtr instead of virDomainObjPtr 2012-01-11 09:52:18 +00:00
security_manager.c Add two new security label types 2012-02-02 17:44:37 -07:00
security_manager.h Add two new security label types 2012-02-02 17:44:37 -07:00
security_nop.c Change security driver APIs to use virDomainDefPtr instead of virDomainObjPtr 2012-01-11 09:52:18 +00:00
security_nop.h Refactor the security drivers to simplify usage 2011-01-10 18:10:52 +00:00
security_selinux.c Add two new security label types 2012-02-02 17:44:37 -07:00
security_selinux.h Refactor the security drivers to simplify usage 2011-01-10 18:10:52 +00:00
security_stack.c Change security driver APIs to use virDomainDefPtr instead of virDomainObjPtr 2012-01-11 09:52:18 +00:00
security_stack.h Refactor the security drivers to simplify usage 2011-01-10 18:10:52 +00:00
virt-aa-helper.c apparmor: Fix use of uninitialized random_data 2012-01-27 11:14:21 +01:00