Bug 542920 - SELinux prevented perl from reading files stored on a NFS filesytem.
Summary: SELinux prevented perl from reading files stored on a NFS filesytem.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 12
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:0b512328993...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-12-01 08:12 UTC by Oron Peled
Modified: 2010-08-20 01:43 UTC (History)
2 users (show)

Fixed In Version: selinux-policy-3.6.32-120.fc12
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-12-07 22:47:22 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Oron Peled 2009-12-01 08:12:45 UTC
Summary:

SELinux prevented perl from reading files stored on a NFS filesytem.

Detailed Description:

SELinux prevented perl from reading files stored on a NFS filesystem. NFS
(Network Filesystem) is a network filesystem commonly used on Unix / Linux
systems. perl attempted to read one or more files or directories from a mounted
filesystem of this type. As NFS filesystems do not support fine-grained SELinux
labeling, all files and directories in the filesystem will have the same
security context. If you have not configured perl to read files from a NFS
filesystem this access attempt could signal an intrusion attempt.

Allowing Access:

Changing the "use_nfs_home_dirs" boolean to true will allow this access:
"setsebool -P use_nfs_home_dirs=1"

Fix Command:

setsebool -P use_nfs_home_dirs=1

Additional Information:

Source Context                system_u:system_r:logwatch_t:s0-s0:c0.c1023
Target Context                system_u:object_r:nfs_t:s0
Target Objects                 [ dir ]
Source                        perl
Source Path                   /usr/bin/perl
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           perl-5.10.0-82.fc12
Target RPM Packages           
Policy RPM                    selinux-policy-3.6.32-46.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   use_nfs_home_dirs
Host Name                     (removed)
Platform                      Linux (removed) 2.6.31.5-127.fc12.i686.PAE #1 SMP Sat
                              Nov 7 21:25:57 EST 2009 i686 i686
Alert Count                   2
First Seen                    Mon 30 Nov 2009 08:13:08 AM IST
Last Seen                     Tue 01 Dec 2009 09:12:07 AM IST
Local ID                      4ec01203-360a-4970-9f33-77e37a677d0c
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1259651527.627:123): avc:  denied  { read } for  pid=4021 comm="perl" name="" dev=0:16 ino=173614 scontext=system_u:system_r:logwatch_t:s0-s0:c0.c1023 tcontext=system_u:object_r:nfs_t:s0 tclass=dir

node=(removed) type=SYSCALL msg=audit(1259651527.627:123): arch=40000003 syscall=5 success=no exit=-13 a0=8e73954 a1=98800 a2=3714ac a3=8dbd008 items=0 ppid=3626 pid=4021 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=15 comm="perl" exe="/usr/bin/perl" subj=system_u:system_r:logwatch_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  selinux-policy-3.6.32-46.fc12,use_nfs_home_dirs,perl,logwatch_t,nfs_t,dir,read
audit2allow suggests:

#============= logwatch_t ==============
allow logwatch_t nfs_t:dir read;

Comment 1 Oron Peled 2009-12-01 08:17:02 UTC
This bug is not new. I get this every day (when logwatch runs from cron) for maybe a year or two), I was simply too lazy to report it until now :-(

[so reporting directly from setroubleshoot proves itself]

Comment 2 Oron Peled 2009-12-01 08:20:03 UTC
An important info -- I obviously flagged use_nfs_home_dirs long time ago:
  [root@neon ~]# getsebool use_nfs_home_dirs
  use_nfs_home_dirs --> on

Comment 3 Daniel Walsh 2009-12-01 12:47:47 UTC
Is logwatch actually setup to look at your homedir?

Comment 4 Daniel Walsh 2009-12-01 12:51:47 UTC
Fixed in selinux-policy-3.6.32-52.fc12.noarch

Comment 5 Fedora Update System 2009-12-01 16:54:52 UTC
selinux-policy-3.6.32-52.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-52.fc12

Comment 6 Fedora Update System 2009-12-03 05:02:19 UTC
selinux-policy-3.6.32-52.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update selinux-policy'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F12/FEDORA-2009-12549

Comment 7 Fedora Update System 2009-12-03 20:26:51 UTC
selinux-policy-3.6.32-55.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-55.fc12

Comment 8 Fedora Update System 2009-12-04 23:44:58 UTC
selinux-policy-3.6.32-55.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update selinux-policy'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F12/FEDORA-2009-12650

Comment 9 Fedora Update System 2009-12-08 07:51:38 UTC
selinux-policy-3.6.32-55.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2010-08-05 13:18:07 UTC
selinux-policy-3.6.32-120.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-120.fc12

Comment 11 Fedora Update System 2010-08-20 01:38:31 UTC
selinux-policy-3.6.32-120.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.


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