Bug 118260

Summary: 'dmesg' fails when in su environment
Product: [Fedora] Fedora Reporter: Tim Waugh <twaugh>
Component: policyAssignee: Daniel Walsh <dwalsh>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: pgraner
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-03-25 05:41:20 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tim Waugh 2004-03-14 17:55:33 UTC
Description of problem:
Although 'dmesg' works fine as a normal non-root user, it doesn't work
in an su environment.

Version-Release number of selected component (if applicable):
1.8-14

How reproducible:
100%

Steps to Reproduce:
1. Log in via gdm as non-root non-staff user
2. Start terminal.
3. su -
4. dmesg
  
Actual results:
No output.

Expected results:
Kernel message log.

Additional info:
avc:  denied  { use } for  pid=3884 exe=/bin/dmesg path=/dev/pts/8
dev= ino=10 scontext=root:system_r:dmesg_t
tcontext=user_u:user_r:user_t tclass=fd

audit2allow says:

allow dmesg_t user_t:fd { use };

Comment 1 Daniel Walsh 2004-03-15 01:18:12 UTC
Fixed in policy-1.8-15.

Dan