Bug 448579 - brctl needs access to /dev/console?
brctl needs access to /dev/console?
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted (Show other bugs)
9
All Linux
low Severity low
: ---
: ---
Assigned To: Daniel Walsh
Ben Levenson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-05-27 13:53 EDT by James Ralston
Modified: 2008-11-17 17:04 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-11-17 17:04:18 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 James Ralston 2008-05-27 13:53:11 EDT
Here's the simplest way to explain the problem:

May 27 10:58:57 hostname kernel: type=1400 audit(1211900331.181:3): avc:  denied
 { read write } for  pid=1957 comm="brctl" path="/dev/console" dev=tmpfs ino=230
scontext=system_u:system_r:brctl_t:s0
tcontext=system_u:object_r:console_device_t:s0 tclass=chr_file

This occurs when networking comes up (e.g., at system startup).  I suspect it
happens because my primary network interface, eth0, is actually a bridge; my
/etc/sysconfig/network-scripts configuration files for br0/eth0 are:

    DEVICE=br0
    TYPE=Bridge
    ONBOOT=yes
    [...]

    DEVICE=eth0
    TYPE=Ethernet
    ONBOOT=yes
    BRIDGE=br0

Now, I can work around this problem by loading a custom module that contains:

allow brctl_t console_device_t:chr_file { read write };

But I'm thinking that since bridging the network interface is necessary for
creating a KVM guest that uses shared physical networking, this policy update
should really go into the targeted policy.

(Alternatively, one might be able to argue that it's a bug that brctl wants to
read/write /dev/console.  But I'm not familiar enough with brctl to make that
assertion.)
Comment 1 Daniel Walsh 2008-05-27 16:05:21 EDT
You can allow this for now by executing 

# audit2allow -M mypol -i /var/log/audit/audit.log 
# semodule -i mypol.pp

Fixed in selinux-policy-3.3.1-56.fc9
Comment 2 Daniel Walsh 2008-11-17 17:04:18 EST
Closing all bugs that have been in modified for over a month.  Please reopen if the bug is not actually fixed.

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