Bug 211779 - AVC denied (write|lock) for comm="mingetty" name="wtmp"
AVC denied (write|lock) for comm="mingetty" name="wtmp"
Status: CLOSED WORKSFORME
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Walsh
Ben Levenson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-10-22 13:06 EDT by Robert Scheck
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-11-09 15:18:32 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Robert Scheck 2006-10-22 13:06:36 EDT
Description of problem:
After rebooting my machine, I found the following AVC denieds:

type=AVC msg=audit(1161535817.537:34): avc:  denied  { write } for  pid=2559 
comm="mingetty" name="wtmp" dev=cciss/c0d0p2 ino=835671 scontext=system_u:
system_r:getty_t:s0 tcontext=user_u:object_r:var_log_t:s0 tclass=file
type=AVC msg=audit(1161535817.537:35): avc:  denied  { lock } for  pid=2560 
comm="mingetty" name="wtmp" dev=cciss/c0d0p2 ino=835671 scontext=system_u:
system_r:getty_t:s0 tcontext=user_u:object_r:var_log_t:s0 tclass=file

Version-Release number of selected component (if applicable):
selinux-policy-targeted-2.3.18-10

How reproducible:
Everytime, see above.

Actual results:
AVC denied (write|lock) for comm="mingetty" name="wtmp"

Expected results:
No AVC denied... ;-)
Comment 1 Daniel Walsh 2006-10-23 10:26:39 EDT
Some how your wtmp file got labeled incorrectly. 


restorecon /var/run/wtmp 

should fix.

Did you run in permissive mode?  Any idea how this got mislabled?
Comment 2 Robert Scheck 2006-10-23 16:13:02 EDT
Yepp, permissive mode. Ideas? Hm, isn't /var/run/wtmp created during booting 
time? Looks like something is self-eating, because really I didn't touch there 
anything.

/sbin/restorecon reset /var/log/wtmp context user_u:object_r:var_log_t:s0-
>system_u:object_r:wtmp_t:s0
Comment 3 Daniel Walsh 2006-10-25 13:45:16 EDT
Are you seeing this come back on reboot?
Comment 4 Robert Scheck 2006-10-28 21:42:57 EDT
Nope...
Comment 5 Daniel Walsh 2006-10-30 09:31:53 EST
I have no idea why this is happening.  init scripts and logrotate would be
logical candidates, but bother seem ok.
Comment 6 Daniel Walsh 2006-11-09 15:18:32 EST
Closing for now.  Added wtmp to restorecond.

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