Bug 546965 - SELinux is preventing /usr/bin/perl "getattr" access on /var/spool/bacula/log.
Summary: SELinux is preventing /usr/bin/perl "getattr" access on /var/spool/bacula/log.
Keywords:
Status: CLOSED DUPLICATE of bug 494037
Alias: None
Product: Fedora
Classification: Fedora
Component: bacula
Version: 12
Hardware: i386
OS: Linux
low
medium
Target Milestone: ---
Assignee: Andreas Thienemann
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:f29445b6f38...
: 557691 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-12-12 22:36 UTC by Piotr Kolaczek
Modified: 2010-01-22 14:05 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-12-18 20:29:07 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Piotr Kolaczek 2009-12-12 22:36:54 UTC
Summary:

SELinux is preventing /usr/bin/perl "getattr" access on /var/spool/bacula/log.

Detailed Description:

SELinux denied access requested by logwatch. It is not expected that this access
is required by logwatch and this access may signal an intrusion attempt. It is
also possible that the specific version or configuration of the application is
causing it to require additional access.

Allowing Access:

You can generate a local policy module to allow this access - see FAQ
(http://fedora.redhat.com/docs/selinux-faq-fc5/#id2961385) Please file a bug
report.

Additional Information:

Source Context                system_u:system_r:logwatch_t:s0-s0:c0.c1023
Target Context                system_u:object_r:var_spool_t:s0
Target Objects                /var/spool/bacula/log [ file ]
Source                        0logwatch
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-55.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     (removed)
Platform                      Linux (removed) 2.6.31.6-162.fc12.i686.PAE #1 SMP
                              Fri Dec 4 00:43:59 EST 2009 i686 i686
Alert Count                   34
First Seen                    Fri 20 Nov 2009 12:16:02 PM CET
Last Seen                     Fri 11 Dec 2009 10:08:02 AM CET
Local ID                      d2a143e9-8398-4f45-9ba7-2c07100685ad
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1260522482.499:123): avc:  denied  { getattr } for  pid=11578 comm="logwatch" path="/var/spool/bacula/log" dev=dm-1 ino=920987 scontext=system_u:system_r:logwatch_t:s0-s0:c0.c1023 tcontext=system_u:object_r:var_spool_t:s0 tclass=file

node=(removed) type=SYSCALL msg=audit(1260522482.499:123): arch=40000003 syscall=195 success=no exit=-13 a0=831c454 a1=82f80c0 a2=a69ff4 a3=82f8008 items=0 ppid=11572 pid=11578 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=14 comm="logwatch" 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-55.fc12,catchall,0logwatch,logwatch_t,var_spool_t,file,getattr
audit2allow suggests:

#============= logwatch_t ==============
allow logwatch_t var_spool_t:file getattr;

Comment 1 Daniel Walsh 2009-12-14 11:59:35 UTC
Why does bacula have its log files in /var/spool/bacula.  Can you move them to /var/log/bacula?

Piotr,  Change the label on the directory to var_log_t and the problem should go away

chcon -t var_log_t -R /var/spool/bacula/log

Comment 2 Paul Howarth 2009-12-18 20:29:07 UTC
I suggested this in Bug #494037, which is over 8 months old now.

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

Comment 3 Daniel Walsh 2010-01-22 14:05:38 UTC
*** Bug 557691 has been marked as a duplicate of this bug. ***


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