[PATCH 4/7] qemu_tpm: Restore TPM labels on failed start

Peter Krempa pkrempa at redhat.com
Tue Jan 3 13:00:49 UTC 2023


On Wed, Dec 21, 2022 at 08:43:54 +0100, Michal Privoznik wrote:
> If swtpm binary fails to start after successful exec() (e.g. it
> fails to initialize itself), the seclabels set in
> qemuSecurityStartTPMEmulator() are not restored. This is due to
> lacking qemuSecurityRestoreTPMLabels() call in the error path.
> 
> Signed-off-by: Michal Privoznik <mprivozn at redhat.com>
> ---
>  src/qemu/qemu_tpm.c | 4 ++++
>  1 file changed, 4 insertions(+)

Reviewed-by: Peter Krempa <pkrempa at redhat.com>


More information about the libvir-list mailing list