Bug 664684 - init_write_script_pipes(load_policy_t)
init_write_script_pipes(load_policy_t)
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: selinux-policy (Show other bugs)
5.7
All Linux
low Severity medium
: rc
: ---
Assigned To: Miroslav Grepl
Milos Malik
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-12-21 05:18 EST by Jan Sarenik
Modified: 2011-07-21 07:50 EDT (History)
2 users (show)

See Also:
Fixed In Version: selinux-policy-2.4.6-301.el5
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-07-21 05:21:32 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jan Sarenik 2010-12-21 05:18:15 EST
Condor package out of MRG product contains following line
in its RPM postinstall scriptlet:

  semanage fcontext -a -t unconfined_execmem_exec_t /usr/sbin/condor_startd

After installing it, I can find AVCs like following one:

  type=AVC msg=audit(1292597868.670:22): avc:  denied  { write } for  pid=4743 comm="load_policy" path="pipe:[16421]" dev=pipefs 

condor-7.4.5-0.3.el5
selinux-policy-2.4.6-279.el5_5.2
selinux-policy-targeted-2.4.6-279.el5_5.2

How reproducible: 100%

Steps to Reproduce:
1. Install condor package on RHEL5
2. Run
/usr/bin/env LC_ALL=en_US.UTF-8 /sbin/ausearch -m AVC -m USER_AVC -m SELINUX_ERR
  
Actual results: denied AVC found
Expected results: no deny
Comment 1 Jan Sarenik 2010-12-21 06:37:03 EST
Hmm, the package have to be installed from
tcontext=user_u:system_r:rpm_script_t:s0 context (not as normal logged-in
root) for the AVCs to appear.

That's the way how scripts are run in Beaker.
Comment 2 Daniel Walsh 2010-12-21 09:06:06 EST
Please attach the entire AVC message.
Comment 4 Jan Sarenik 2010-12-21 09:10:36 EST
time->Fri Dec 17 09:57:48 2010
type=SYSCALL msg=audit(1292597868.670:22): arch=40000003 syscall=11 success=yes exit=0 a0=94b1f18 a1=af28060 a2=0 a3=0 items=0 ppid=4694 pid=4743 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="load_policy" exe="/usr/sbin/load_policy" subj=system_u:system_r:load_policy_t:s0 key=(null)
type=AVC msg=audit(1292597868.670:22): avc:  denied  { write } for  pid=4743 comm="load_policy" path="pipe:[16421]" dev=pipefs ino=16421 scontext=system_u:system_r:load_policy_t:s0 tcontext=system_u:system_r:initrc_t:s0 tclass=fifo_file
type=AVC msg=audit(1292597868.670:22): avc:  denied  { write } for  pid=4743 comm="load_policy" path="pipe:[16421]" dev=pipefs
Comment 5 Miroslav Grepl 2011-03-01 12:10:17 EST
Fixed in selinux-policy-2.4.6-301.el5
Comment 8 errata-xmlrpc 2011-07-21 05:21:32 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-1069.html
Comment 9 errata-xmlrpc 2011-07-21 07:50:06 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-1069.html

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