Bug 674912

Summary: several avc denied for mount of /etc/mtab at first boot of fresh install
Product: [Fedora] Fedora Reporter: John Reiser <jreiser>
Component: util-linuxAssignee: Karel Zak <kzak>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: dwalsh, jonathan, kzak
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-02-04 14:24:46 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description John Reiser 2011-02-03 17:55:05 UTC
Description of problem: Upon first boot after fresh install, there are several selinux complaints (avc denied) relating to mount of /etc/mtab.


Version-Release number of selected component (if applicable):
util-linux-2.19-0.4.fc15.x86_64
selinux-policy-targeted-3.9.13-8.fc15.noarch
systemd-17-1.fc15.x86_64


How reproducible: every time


Steps to Reproduce:
1. Fresh install DVD of today's rawhide (2011-02-03; Thursday)
2. boot
3.
  
Actual results: On text console and in output of dmesg:
[    8.875110] type=1400 audit(1296752507.598:5): avc:  denied  { getattr } for  pid=494 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[    8.880902] type=1400 audit(1296752507.603:6): avc:  denied  { getattr } for  pid=492 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[    8.887511] type=1400 audit(1296752507.610:7): avc:  denied  { getattr } for  pid=493 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[    8.890804] type=1400 audit(1296752507.613:8): avc:  denied  { read } for  pid=492 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[    8.896335] type=1400 audit(1296752507.619:9): avc:  denied  { read } for  pid=493 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[    8.903736] type=1400 audit(1296752507.626:10): avc:  denied  { read } for  pid=494 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[    9.036702] type=1400 audit(1296752507.758:11): avc:  denied  { getattr } for  pid=498 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   14.206746] type=1400 audit(1296752512.928:19): avc:  denied  { getattr } for  pid=896 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   14.208596] type=1400 audit(1296752512.931:20): avc:  denied  { read } for  pid=896 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   14.232449] type=1400 audit(1296752512.954:21): avc:  denied  { getattr } for  pid=898 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   14.234403] type=1400 audit(1296752512.956:22): avc:  denied  { read } for  pid=898 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   15.569986] type=1400 audit(1296752514.291:23): avc:  denied  { create } for  pid=918 comm="system-setup-ke" name="00-system-setup-keyboard.conf" scontext=system_u:system_r:keyboardd_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=file
[   15.632222] type=1400 audit(1296752514.354:24): avc:  denied  { getattr } for  pid=926 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   15.633710] type=1400 audit(1296752514.356:25): avc:  denied  { read } for  pid=926 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   15.641302] type=1400 audit(1296752514.363:26): avc:  denied  { getattr } for  pid=927 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   15.642926] type=1400 audit(1296752514.365:27): avc:  denied  { read } for  pid=927 comm="mount" name="mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file
[   15.648116] type=1400 audit(1296752514.370:28): avc:  denied  { getattr } for  pid=928 comm="mount" path="/etc/mtab" dev=sdd7 ino=131347 scontext=system_u:system_r:mount_t:s0 tcontext=system_u:object_r:etc_runtime_t:s0 tclass=lnk_file



Expected results: no complaint


Additional info:

Comment 1 Karel Zak 2011-02-04 11:18:00 UTC
Dan, it seems that SELinux doesn't like the fact that /etc/mtab is a symlink. Is there anything what should be fixed in selinux policy?

Comment 2 Daniel Walsh 2011-02-04 14:24:46 UTC
Fixed in selinux-policy-3.9.13-10.fc15