Bug 1649665 - SELinux is preventing /usr/lib/systemd/systemd-timesyncd from 'search' accesses on the directory /var/lib/systemd.
Summary: SELinux is preventing /usr/lib/systemd/systemd-timesyncd from 'search' access...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 29
Hardware: x86_64
OS: Unspecified
high
high
Target Milestone: ---
Assignee: Lukas Vrabec
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:882410a7da05e5bc31ca1f9830d...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-11-14 07:58 UTC by Sumit Bhardwaj
Modified: 2019-01-17 02:16 UTC (History)
5 users (show)

Fixed In Version: selinux-policy-3.14.2-46.fc29
Clone Of:
Environment:
Last Closed: 2019-01-17 02:16:54 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Sumit Bhardwaj 2018-11-14 07:58:30 UTC
Description of problem:
SELinux is preventing /usr/lib/systemd/systemd-timesyncd from 'search' accesses on the directory /var/lib/systemd.

*****  Plugin catchall (100. confidence) suggests   **************************

If you believe that systemd-timesyncd should be allowed search access on the systemd directory by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
Do
allow this access for now by executing:
# ausearch -c 'systemd-timesyn' --raw | audit2allow -M my-systemdtimesyn
# semodule -X 300 -i my-systemdtimesyn.pp

Additional Information:
Source Context                system_u:system_r:systemd_timedated_t:s0
Target Context                system_u:object_r:init_var_lib_t:s0
Target Objects                /var/lib/systemd [ dir ]
Source                        systemd-timesyn
Source Path                   /usr/lib/systemd/systemd-timesyncd
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           systemd-udev-239-6.git9f3aed1.fc29.x86_64
Target RPM Packages           systemd-239-6.git9f3aed1.fc29.x86_64
Policy RPM                    selinux-policy-3.14.2-42.fc29.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Permissive
Host Name                     (removed)
Platform                      Linux (removed) 4.18.17-300.fc29.x86_64 #1 SMP Mon
                              Nov 5 17:56:16 UTC 2018 x86_64 x86_64
Alert Count                   1
First Seen                    2018-11-14 12:59:17 IST
Last Seen                     2018-11-14 12:59:17 IST
Local ID                      f05bfe43-dce9-4d54-8da3-48dd564fa76c

Raw Audit Messages
type=AVC msg=audit(1542180557.269:84): avc:  denied  { search } for  pid=741 comm="systemd-timesyn" name="systemd" dev="sda3" ino=1444811 scontext=system_u:system_r:systemd_timedated_t:s0 tcontext=system_u:object_r:init_var_lib_t:s0 tclass=dir permissive=1


type=AVC msg=audit(1542180557.269:84): avc:  denied  { read } for  pid=741 comm="systemd-timesyn" name="timesync" dev="sda3" ino=1444885 scontext=system_u:system_r:systemd_timedated_t:s0 tcontext=system_u:object_r:init_var_lib_t:s0 tclass=lnk_file permissive=1


type=SYSCALL msg=audit(1542180557.269:84): arch=x86_64 syscall=openat success=no exit=EACCES a0=ffffff9c a1=55d118756238 a2=80002 a3=0 items=0 ppid=1 pid=741 auid=4294967295 uid=963 gid=963 euid=963 suid=963 fsuid=963 egid=963 sgid=963 fsgid=963 tty=(none) ses=4294967295 comm=systemd-timesyn exe=/usr/lib/systemd/systemd-timesyncd subj=system_u:system_r:systemd_timedated_t:s0 key=(null)

Hash: systemd-timesyn,systemd_timedated_t,init_var_lib_t,dir,search

Version-Release number of selected component:
selinux-policy-3.14.2-42.fc29.noarch

Additional info:
component:      selinux-policy
reporter:       libreport-2.9.6
hashmarkername: setroubleshoot
kernel:         4.18.17-300.fc29.x86_64
type:           libreport

Comment 1 Lukas Vrabec 2018-12-17 18:39:43 UTC
This Pull request fixing the issue: 

https://github.com/fedora-selinux/selinux-policy/pull/235

Comment 2 Fedora Update System 2019-01-13 15:45:13 UTC
selinux-policy-3.14.2-46.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-6a20cfef61

Comment 3 Fedora Update System 2019-01-14 03:03:25 UTC
selinux-policy-3.14.2-46.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-2019-6a20cfef61

Comment 4 Fedora Update System 2019-01-17 02:16:54 UTC
selinux-policy-3.14.2-46.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.