]> xenbits.xensource.com Git - libvirt.git/commit
security_dac: Set DAC label on SGX /dev nodes
authorMichal Privoznik <mprivozn@redhat.com>
Fri, 11 Nov 2022 01:21:26 +0000 (17:21 -0800)
committerMichal Privoznik <mprivozn@redhat.com>
Fri, 11 Nov 2022 13:06:45 +0000 (14:06 +0100)
commit320459b8c68dab96159c3d4d88c64aa55c4f19ea
treee5fe23b3356619f9599277569fd71fdaf39f70b2
parent83bb0f0ee12f7db1487232b736d953375a9c144e
security_dac: Set DAC label on SGX /dev nodes

As advertised in previous commits, QEMU needs to access
/dev/sgx_vepc and /dev/sgx_provision files when SGX memory
backend is configured. And if it weren't for QEMU's namespaces,
we wouldn't dare to relabel them, because they are system wide
files. But if namespaces are used, then we can set label on
domain's private copies, just like we do for /dev/sev.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Haibin Huang <haibin.huang@intel.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/security/security_dac.c