RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 855895 - AVCs when running cyrus-imapd test with disabled unconfined and unlabelednet
Summary: AVCs when running cyrus-imapd test with disabled unconfined and unlabelednet
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: selinux-policy
Version: 6.4
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Miroslav Grepl
QA Contact: Milos Malik
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-09-10 14:43 UTC by Michal Trunecka
Modified: 2014-09-30 23:33 UTC (History)
3 users (show)

Fixed In Version: selinux-policy-3.7.19-182.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-02-21 08:29:06 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2013:0314 0 normal SHIPPED_LIVE selinux-policy bug fix and enhancement update 2013-02-20 20:35:01 UTC

Description Michal Trunecka 2012-09-10 14:43:47 UTC
Description of problem:
Cyrus-imapd automated test failed and reported AVCs listed below when unconfined and unlabelednet selinux modules disabled. Test passes without eny AVCs with both modules enabled.

----
time->Mon Sep 10 16:33:09 2012
type=PATH msg=audit(1347287589.905:3237): item=0 name="/var/lib/imap/rpm/db_import.log" inode=27511 dev=08:03 mode=0100600 ouid=76 ogid=12 rdev=00:00 obj=unconfined_u:object_r:cyrus_var_lib_t:s0
type=CWD msg=audit(1347287589.905:3237):  cwd="/var/lib/imap"
type=SYSCALL msg=audit(1347287589.905:3237): arch=c000003e syscall=2 success=no exit=-13 a0=1baf890 a1=241 a2=1b6 a3=76 items=1 ppid=3796 pid=3809 auid=0 uid=76 gid=12 euid=76 suid=76 fsuid=76 egid=12 sgid=12 fsgid=12 tty=(none) ses=3 comm="sh" exe="/bin/bash" subj=unconfined_u:system_r:initrc_t:s0 key=(null)
type=AVC msg=audit(1347287589.905:3237): avc:  denied  { write } for  pid=3809 comm="sh" name="db_import.log" dev=sda3 ino=27511 scontext=unconfined_u:system_r:initrc_t:s0 tcontext=unconfined_u:object_r:cyrus_var_lib_t:s0 tclass=file
----
time->Mon Sep 10 16:33:09 2012
type=PATH msg=audit(1347287589.906:3238): item=0 name="/var/lib/imap/rpm/db_import.log" inode=27511 dev=08:03 mode=0100600 ouid=76 ogid=12 rdev=00:00 obj=unconfined_u:object_r:cyrus_var_lib_t:s0
type=CWD msg=audit(1347287589.906:3238):  cwd="/var/lib/imap"
type=SYSCALL msg=audit(1347287589.906:3238): arch=c000003e syscall=2 success=no exit=-13 a0=1baf890 a1=201 a2=1b6 a3=76 items=1 ppid=3796 pid=3809 auid=0 uid=76 gid=12 euid=76 suid=76 fsuid=76 egid=12 sgid=12 fsgid=12 tty=(none) ses=3 comm="sh" exe="/bin/bash" subj=unconfined_u:system_r:initrc_t:s0 key=(null)
type=AVC msg=audit(1347287589.906:3238): avc:  denied  { write } for  pid=3809 comm="sh" name="db_import.log" dev=sda3 ino=27511 scontext=unconfined_u:system_r:initrc_t:s0 tcontext=unconfined_u:object_r:cyrus_var_lib_t:s0 tclass=file
----
time->Mon Sep 10 16:33:14 2012
type=PATH msg=audit(1347287594.224:3243): item=0 name="/var/lib/imap/rpm/db_export.log" inode=27515 dev=08:03 mode=0100600 ouid=76 ogid=12 rdev=00:00 obj=unconfined_u:object_r:cyrus_var_lib_t:s0
type=CWD msg=audit(1347287594.224:3243):  cwd="/var/lib/imap"
type=SYSCALL msg=audit(1347287594.224:3243): arch=c000003e syscall=2 success=no exit=-13 a0=1a0d890 a1=241 a2=1b6 a3=76 items=1 ppid=3881 pid=3894 auid=0 uid=76 gid=12 euid=76 suid=76 fsuid=76 egid=12 sgid=12 fsgid=12 tty=(none) ses=3 comm="sh" exe="/bin/bash" subj=unconfined_u:system_r:initrc_t:s0 key=(null)
type=AVC msg=audit(1347287594.224:3243): avc:  denied  { write } for  pid=3894 comm="sh" name="db_export.log" dev=sda3 ino=27515 scontext=unconfined_u:system_r:initrc_t:s0 tcontext=unconfined_u:object_r:cyrus_var_lib_t:s0 tclass=file
----
time->Mon Sep 10 16:33:14 2012
type=PATH msg=audit(1347287594.225:3244): item=0 name="/var/lib/imap/rpm/db_export.log" inode=27515 dev=08:03 mode=0100600 ouid=76 ogid=12 rdev=00:00 obj=unconfined_u:object_r:cyrus_var_lib_t:s0
type=CWD msg=audit(1347287594.225:3244):  cwd="/var/lib/imap"
type=SYSCALL msg=audit(1347287594.225:3244): arch=c000003e syscall=2 success=no exit=-13 a0=1a0d890 a1=201 a2=1b6 a3=76 items=1 ppid=3881 pid=3894 auid=0 uid=76 gid=12 euid=76 suid=76 fsuid=76 egid=12 sgid=12 fsgid=12 tty=(none) ses=3 comm="sh" exe="/bin/bash" subj=unconfined_u:system_r:initrc_t:s0 key=(null)
type=AVC msg=audit(1347287594.225:3244): avc:  denied  { write } for  pid=3894 comm="sh" name="db_export.log" dev=sda3 ino=27515 scontext=unconfined_u:system_r:initrc_t:s0 tcontext=unconfined_u:object_r:cyrus_var_lib_t:s0 tclass=file

Version-Release number of selected component (if applicable):
cyrus-imapd-2.3.16-6.el6_2.5.x86_64
selinux-policy-3.7.19-160.el6.noarch
selinux-policy-targeted-3.7.19-160.el6.noarch

How reproducible:
always

Steps to Reproduce:
1. semoudle -d unconfined; semodule -d unlabelednet
2. Run automated test:
/CoreOS/selinux-policy/Regression/bz504805-cyrus-master-and-mupdate-port
  
Actual results:
Test fails

Expected results:
Test passes without AVCs.

Comment 6 Miroslav Grepl 2012-11-27 14:48:22 UTC
Fixed in selinux-policy-3.7.19-182.el6

# sesearch -A -s initrc_t -t cyrus_var_lib_t -c dir
Found 3 semantic av rules:
   allow initrc_t cyrus_var_lib_t : dir { ioctl read write getattr lock add_name remove_name search open } ;

Comment 12 Miroslav Grepl 2012-12-03 13:04:26 UTC
Milos, I am switching it back to ON_QA.

#============= initrc_t ==============
#!!!! This avc is a constraint violation.  You will need to add an attribute to either the source or target type to make it work.
#Contraint rule: 
allow initrc_t cyrus_var_lib_t:file create;
allow initrc_t cyrus_var_lib_t:file { relabelfrom relabelto };

This should be created as a new cyrus bug.

Comment 14 errata-xmlrpc 2013-02-21 08:29:06 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2013-0314.html


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