Bug 1645770
| Summary: | selinux is blocking gdm from accessing dosfs_t files, breaking the grub hidden menu feature | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Hans de Goede <hdegoede> |
| Component: | selinux-policy-targeted | Assignee: | Lukas Vrabec <lvrabec> |
| Status: | CLOSED ERRATA | QA Contact: | Ben Levenson <benl> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 29 | CC: | dwalsh |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-11-09 06:02:01 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: | |||
commit 62d90da2a38c1a701a5f177feb861d0d75357d55 (HEAD -> rawhide)
Author: Lukas Vrabec <lvrabec>
Date: Sun Nov 4 18:05:48 2018 +0100
Allow xdm_t domain to manage dosfs_t files BZ(1645770)
selinux-policy-3.14.2-42.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-3129f981d3 selinux-policy-3.14.2-42.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-3129f981d3 selinux-policy-3.14.2-42.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report. |
When rebooting using the GNOME3 system menu from within gdm, gnome-session calls the grub2-set-bootflag helper to modify the grubenv (which sets on the UEFI ESP partition which is vfat) to indicate that this was a user initiated reboot and that the previous boot thus was successful, so that the grub menu will stay hidden. This currently does not work with selinux in enforcing mode. Strange enough I only get 1 AVC in audit.log and only when selinux is in permissive mode, it seems that the earlier read deny does not logged? The AVC which I got is: type=AVC msg=audit(1541252809.861:288): avc: denied { write } for pid=4632 comm="grub2-set-bootf" name="grubenv" dev="nvme0n1p1" ino=5 scontext=system_u:system_r:xdm_t:s0-s0:c0.c1023 tcontext=system_u:object_r:dosfs_t:s0 tclass=file permissive=1 Anyways with some help from audit2allow + a small manual edit I've managed to fix this locally using a selinux module with the following allow line in there: allow xdm_t dosfs_t:file { open read write } ; Can the official Fedora selinux policy please be modified to allow gdm (xdm_t) access to dosfs_t files?