Bug 564564 - SELinux is preventing /usr/sbin/logrotate "write" access on /opt/zimbra/log/zmlogswatch.out.
Summary: SELinux is preventing /usr/sbin/logrotate "write" access on /opt/zimbra/log/z...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 12
Hardware: x86_64
OS: Linux
low
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:2aa668b24c8...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-02-13 11:32 UTC by galerien
Modified: 2010-03-04 00:15 UTC (History)
3 users (show)

Fixed In Version: selinux-policy-3.6.32-92.fc12
Clone Of:
Environment:
Last Closed: 2010-03-04 00:15:01 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description galerien 2010-02-13 11:32:51 UTC
Résumé:

SELinux is preventing /usr/sbin/logrotate "write" access on
/opt/zimbra/log/zmlogswatch.out.

Description détaillée:

SELinux denied access requested by logrotate. It is not expected that this
access is required by logrotate 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.

Autoriser l'accès:

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

Informations complémentaires:

Contexte source               system_u:system_r:logrotate_t:s0-s0:c0.c1023
Contexte cible                system_u:object_r:usr_t:s0
Objets du contexte            /opt/zimbra/log/zmlogswatch.out [ file ]
source                        logrotate
Chemin de la source           /usr/sbin/logrotate
Port                          <Inconnu>
Hôte                         (removed)
Paquetages RPM source         logrotate-3.7.8-5.fc12
Paquetages RPM cible          
Politique RPM                 selinux-policy-3.6.32-84.fc12
Selinux activé               True
Type de politique             targeted
Mode strict                   Enforcing
Nom du plugin                 catchall
Nom de l'hôte                (removed)
Plateforme                    Linux (removed)
                              2.6.31.12-174.2.3.fc12.x86_64 #1 SMP Mon Jan 18
                              19:52:07 UTC 2010 x86_64 x86_64
Compteur d'alertes            2
Première alerte              lun. 08 févr. 2010 08:13:02 CET
Dernière alerte              sam. 13 févr. 2010 10:10:02 CET
ID local                      59cdb654-3f33-4614-967a-e3004fb61ee0
Numéros des lignes           

Messages d'audit bruts        

node=(removed) type=AVC msg=audit(1266052202.538:130364): avc:  denied  { write } for  pid=2190 comm="logrotate" name="zmlogswatch.out" dev=sdc5 ino=8356602 scontext=system_u:system_r:logrotate_t:s0-s0:c0.c1023 tcontext=system_u:object_r:usr_t:s0 tclass=file

node=(removed) type=SYSCALL msg=audit(1266052202.538:130364): arch=c000003e syscall=2 success=no exit=-13 a0=632380 a1=2 a2=7fff55e6ff8f a3=6165726373662f72 items=0 ppid=2167 pid=2190 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=18 comm="logrotate" exe="/usr/sbin/logrotate" subj=system_u:system_r:logrotate_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  catchall,logrotate,logrotate_t,usr_t,file,write
audit2allow suggests:

#============= logrotate_t ==============
allow logrotate_t usr_t:file write;

Comment 1 Daniel Walsh 2010-02-13 14:07:08 UTC
WHy is zibra putting its log files in /opt/zimbra/log.

That is broken.  Please open a bug with them to move it to /var/log
 galerien, execute 
# chcon -t var_log_t -R /opt/zimbra/log
which will fix it.

Miroslav could you add

/opt/zimbra/log(/.*)?		gen_context(system_u:object_r:var_log_t,s0)

Comment 2 Miroslav Grepl 2010-02-15 11:06:34 UTC
Fixed in selinux-policy-3.6.32-91.fc12

Comment 3 Fedora Update System 2010-02-23 20:55:51 UTC
selinux-policy-3.6.32-92.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/selinux-policy-3.6.32-92.fc12

Comment 4 Fedora Update System 2010-02-26 03:42:31 UTC
selinux-policy-3.6.32-92.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-2010-2953

Comment 5 Fedora Update System 2010-03-04 00:11:15 UTC
selinux-policy-3.6.32-92.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.