Bug 543423 - SELinux is preventing nm-system-setti (NetworkManager_t) "unlink" to /etc/NetworkManager/nm-system-settings.conf (etc_t).
Summary: SELinux is preventing nm-system-setti (NetworkManager_t) "unlink" to /etc/Net...
Keywords:
Status: CLOSED DUPLICATE of bug 538428
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 12
Hardware: i386
OS: Linux
low
medium
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:57c007bb7ac...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-12-02 11:14 UTC by Iftikhar
Modified: 2009-12-02 11:16 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2009-12-02 11:16:07 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Iftikhar 2009-12-02 11:14:41 UTC
Summary:

SELinux is preventing nm-system-setti (NetworkManager_t) "unlink" to
/etc/NetworkManager/nm-system-settings.conf (etc_t).

Detailed Description:

SELinux is preventing nm-system-setti (NetworkManager_t) "unlink" to
/etc/NetworkManager/nm-system-settings.conf (etc_t). The SELinux type etc_t, is
a generic type for all files in the directory and very few processes (SELinux
Domains) are allowed to write to this SELinux type. This type of denial usual
indicates a mislabeled file. By default a file created in a directory has the
gets the context of the parent directory, but SELinux policy has rules about the
creation of directories, that say if a process running in one SELinux Domain
(D1) creates a file in a directory with a particular SELinux File Context (F1)
the file gets a different File Context (F2). The policy usually allows the
SELinux Domain (D1) the ability to write, unlink, and append on (F2). But if for
some reason a file (/etc/NetworkManager/nm-system-settings.conf) was created
with the wrong context, this domain will be denied. The usual solution to this
problem is to reset the file context on the target file, restorecon -v
'/etc/NetworkManager/nm-system-settings.conf'. If the file context does not
change from etc_t, then this is probably a bug in policy. Please file a bug
report (http://bugzilla.redhat.com/bugzilla/enter_bug.cgi) against the
selinux-policy package. If it does change, you can try your application again to
see if it works. The file context could have been mislabeled by editing the file
or moving the file from a different directory, if the file keeps getting
mislabeled, check the init scripts to see if they are doing something to
mislabel the file.

Allowing Access:

You can attempt to fix file context by executing restorecon -v
'/etc/NetworkManager/nm-system-settings.conf'

Fix Command:

restorecon '/etc/NetworkManager/nm-system-settings.conf'

Additional Information:

Source Context                system_u:system_r:NetworkManager_t:s0-s0:c0.c1023
Target Context                system_u:object_r:etc_t:s0
Target Objects                /etc/NetworkManager/nm-system-settings.conf [ file
                              ]
Source                        nm-system-setti
Source Path                   /usr/sbin/nm-system-settings
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           NetworkManager-0.7.1-8.git20090708.fc11
Target RPM Packages           NetworkManager-0.7.1-8.git20090708.fc11
Policy RPM                    selinux-policy-3.6.12-82.fc11
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   mislabeled_file
Host Name                     (removed)
Platform                      Linux (removed) 2.6.30.5-43.fc11.i586 #1 SMP
                              Thu Aug 27 21:18:54 EDT 2009 i686 i686
Alert Count                   1
First Seen                    Tue 29 Sep 2009 02:09:33 PM BST
Last Seen                     Tue 29 Sep 2009 02:09:33 PM BST
Local ID                      2d11454e-8ac1-42f7-b54b-17bc7bf6da15
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1254229773.643:16): avc:  denied  { unlink } for  pid=1519 comm="nm-system-setti" name="nm-system-settings.conf" dev=dm-0 ino=3383730 scontext=system_u:system_r:NetworkManager_t:s0-s0:c0.c1023 tcontext=system_u:object_r:etc_t:s0 tclass=file

node=(removed) type=SYSCALL msg=audit(1254229773.643:16): arch=40000003 syscall=38 success=no exit=-13 a0=9fc7490 a1=9fb6528 a2=2b1a1a4 a3=b80916e0 items=0 ppid=1 pid=1519 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="nm-system-setti" exe="/usr/sbin/nm-system-settings" subj=system_u:system_r:NetworkManager_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  selinux-policy-3.6.12-82.fc11,mislabeled_file,nm-system-setti,NetworkManager_t,etc_t,file,unlink
audit2allow suggests:

#============= NetworkManager_t ==============
allow NetworkManager_t etc_t:file unlink;

Comment 1 Miroslav Grepl 2009-12-02 11:16:07 UTC

*** This bug has been marked as a duplicate of bug 538428 ***


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