]> xenbits.xensource.com Git - libvirt.git/commit
Add a test suite for validating SELinux labelling
authorDaniel P. Berrange <berrange@redhat.com>
Wed, 19 Sep 2012 13:00:34 +0000 (14:00 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Mon, 14 Jan 2013 13:40:04 +0000 (13:40 +0000)
commit907a39e735d256b8428ed4c77009d1f713aea19b
tree6315baa531ea88deafbd15f3319dd0e4ce550612
parentcf7ac00ebd99c2817644cfb73fe5f41a9606725a
Add a test suite for validating SELinux labelling

There are many aspects of the guest XML which result in the
SELinux driver applying file labelling. With the increasing
configuration options it is desirable to test this behaviour.
It is not possible to assume that the test suite has the
ability to set SELinux labels. Most filesystems though will
support extended attributes. Thus for the purpose of testing,
it is possible to extend the existing LD_PRELOAD hack to
override setfilecon() and getfilecon() to simply use the
'user.libvirt.selinux' attribute for the sake of testing.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
15 files changed:
.gitignore
HACKING
cfg.mk
configure.ac
libvirt.spec.in
m4/virt-attr.m4 [new file with mode: 0644]
tests/Makefile.am
tests/securityselinuxhelper.c
tests/securityselinuxlabeldata/chardev.txt [new file with mode: 0644]
tests/securityselinuxlabeldata/chardev.xml [new file with mode: 0644]
tests/securityselinuxlabeldata/disks.txt [new file with mode: 0644]
tests/securityselinuxlabeldata/disks.xml [new file with mode: 0644]
tests/securityselinuxlabeldata/kernel.txt [new file with mode: 0644]
tests/securityselinuxlabeldata/kernel.xml [new file with mode: 0644]
tests/securityselinuxlabeltest.c [new file with mode: 0644]