Bug 1321301

Summary: avc denied { append } for pid=9765 comm="restorecon" path="/home/vstart.log"
Product: Red Hat Enterprise Linux 6 Reporter: Li Shuang <shuali>
Component: selinux-policyAssignee: Lukas Vrabec <lvrabec>
Status: CLOSED NOTABUG QA Contact: BaseOS QE Security Team <qe-baseos-security>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.8CC: dwalsh, lvrabec, mgrepl, mmalik, plautrba, pvrabec, ssekidde
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-01 08:53:12 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:

Description Li Shuang 2016-03-25 10:08:29 UTC
Description of problem:
AVC denial in logs

Version-Release number of selected component (if applicable):
RHEL-6.8-20160323.0 ==> kernel-2.6.32-634.el6

How reproducible:
always

Steps to Reproduce:
1. clone this job (only supported well in nay lab):
https://beaker.engineering.redhat.com/jobs/1278781

Actual results:
type=SYSCALL msg=audit(1458792382.599:32): arch=c000003e syscall=59 success=yes exit=0 a0=1bebdb0 a1=1af9c00 a2=1bbe1c0 a3=7fff8fe46890 items=0 ppid=9509 pid=9765 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="restorecon" exe="/sbin/setfiles" subj=unconfined_u:unconfined_r:setfiles_t:s0-s0:c0.c1023 key=(null)
type=AVC msg=audit(1458792382.599:32): avc:  denied  { append } for  pid=9765 comm="restorecon" path="/home/vstart.log" dev=dm-2 ino=12 scontext=unconfined_u:unconfined_r:setfiles_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:home_root_t:s0 tclass=file
Fail: AVC messages found.

Expected results:
No errors 

Additional info:
Could it be related to /home/vstart.log file writing by python?
self._file = "/home/vstart.conf"
...
cfg = ConfigParser.ConfigParser()
...
cfg.write(open(self._file, "w"))

http://pkgs.devel.redhat.com/cgit/tests/kernel/tree/networking/common/vm/vmconf.py