Bug 1739994
Summary: | swtpm gets 'bin_t' context type after first installation, selinux preventing libvirt to execute it | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux Advanced Virtualization | Reporter: | Yanqiu Zhang <yanqzhan> |
Component: | swtpm | Assignee: | Marc-Andre Lureau <marcandre.lureau> |
Status: | CLOSED ERRATA | QA Contact: | Xin WANG <xwan> |
Severity: | unspecified | Docs Contact: | |
Priority: | medium | ||
Version: | 8.1 | CC: | areis, chhu, ddepaula, dyuan, marcandre.lureau, xwan, yafu, yanqzhan |
Target Milestone: | rc | ||
Target Release: | 8.1 | ||
Hardware: | x86_64 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | 0.1.0-1.20190425gitca85606.module+el8.1.0+3966+4a23dca1.1 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2019-11-06 07:18:29 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Yanqiu Zhang
2019-08-12 04:07:06 UTC
I can't reproduce, the file is correctly labelled. Is it only me? (In reply to Marc-Andre Lureau from comment #1) > I can't reproduce, the file is correctly labelled. Is it only me? Hi, Have you installed swtpm before? My colleagues and I tried 4 hosts that never installed it before, all reproduces. A latest try: 73 yum install swtpm 74 ls -lZ /usr/bin/swtpm -rwxr-xr-x. 1 root root system_u:object_r:bin_t:s0 45504 Jun 27 12:22 /usr/bin/swtpm Ok, with a fresh rhel8, I could reproduce. Indeed, the problem is that selinux module isn't installed by the time /usr/bin/swtpm is written. Either we split the package and depend on -selinux, or we add restorecon /usr/bin/swtpm in %post. I would opt for the second, and the fedora maintainer did the same. I am trying to get a test build before I claim this is solved. 0.1.0-1.20190425gitca85606.module+el8.1.0+3966+4a23dca1.1 is already part of virt:8.1, I checked it works on first install. Please verify, thanks Danilo, was the bug supposed to move to ON_QA when integrated in virt:8.1 module? we need QA_ACK in order to add this to the errata. But I see there's no QA assigned to this. Who's triaging AV bz Ademar? @Marc-Andre: it goes to ON_QA automagically when we add it to the errata. But we can't add ON_QA. They need to be MODIFIED (means it's built) or VERIFIED. Let's try yanqzhan for the qa_ack adjustment. Verify this bug with: swtpm-0.1.0-1.20190425gitca85606.module+el8.1.0+3966+4a23dca1.1.x86_64 Swtpm-tools-0.1.0-1.20190425gitca85606.module+el8.1.0+3966+4a23dca1.1.x86_64 Edk2-ovmf-20190308git89910a39dcfd-6.el8 qemu-kvm-4.1.0-10.module+el8.1.0+4234+33aa4f57.x86_64 libvirt-daemon-5.6.0-6.virtcov.el8.x86_64 selinux-policy-3.14.3-20.el8.noarch Steps to verify: Freshly install swtpm, swtpm-tools, etk2-ovmf # yum install swtpm # yum install swtpm-tools # yum install etk2-ovmf # virsh dumpxml rhel8 | grep tpm <tpm model='tpm-crb'> <backend type='emulator' version='2.0'/> <alias name='tpm0'/> </tpm> [root@server ~]# getenforce Enforcing [root@server ~]# virsh start rhel8 Domain rhel8 started [root@server ~]# ausearch -m AVC -ts recent <no matches> [root@server ~]# ls -lZ /usr/bin/swtpm -rwxr-xr-x. 1 root root system_u:object_r:swtpm_exec_t:s0 45632 Aug 15 13:07 /usr/bin/swtpm Since the test result is as expected, mark this bug as verified Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2019:3723 |