Bug 674689 - pyzor with nfs home directories
Summary: pyzor with nfs home directories
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: selinux-policy
Version: 5.5
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: 2011-02-02 22:24 UTC by Orion Poplawski
Modified: 2012-10-16 11:23 UTC (History)
2 users (show)

Fixed In Version: selinux-policy-2.4.6-301.el5
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-07-21 09:19:44 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:1069 0 normal SHIPPED_LIVE selinux-policy bug fix and enhancement update 2011-07-21 09:18:27 UTC

Description Orion Poplawski 2011-02-02 22:24:13 UTC
Description of problem:

pyzor needs to write some files into users' home directories, namely:

/home/<user>/.pyzor/servers

Running on a server with nfs mounted home directories and use_nfs_home_dirs --> on I get:

type=AVC msg=audit(1296684776.239:43866): avc:  denied  { search } for  pid=15209 comm="pyzor" name="" dev=0:1c ino=4288665 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=dir
type=AVC msg=audit(1296684776.262:43867): avc:  denied  { write } for  pid=15209 comm="pyzor" name="" dev=0:1c ino=4288665 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=dir
type=AVC msg=audit(1296684776.262:43867): avc:  denied  { add_name } for  pid=15209 comm="pyzor" name=".pyzor" scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=dir
type=AVC msg=audit(1296684776.262:43867): avc:  denied  { create } for  pid=15209 comm="pyzor" name=".pyzor" scontext=root:system_r:pyzor_t:s0 tcontext=root:object_r:nfs_t:s0 tclass=dir
type=AVC msg=audit(1296684776.354:43868): avc:  denied  { create } for  pid=15209 comm="pyzor" name="servers" scontext=root:system_r:pyzor_t:s0 tcontext=root:object_r:nfs_t:s0 tclass=file
type=AVC msg=audit(1296684776.355:43869): avc:  denied  { getattr } for  pid=15209 comm="pyzor" path="/home/vasha/.pyzor/servers" dev=0:1c ino=4292648 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=file
type=AVC msg=audit(1296684776.356:43870): avc:  denied  { write } for  pid=15209 comm="pyzor" path="/home/vasha/.pyzor/servers" dev=0:1c ino=4292648 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=file
type=AVC msg=audit(1296684776.356:43871): avc:  denied  { read } for  pid=15209 comm="pyzor" name="servers" dev=0:1c ino=4292648 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=file
type=AVC msg=audit(1296684821.926:43872): avc:  denied  { search } for  pid=15273 comm="pyzor" name="" dev=0:1c ino=12308737 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=dir
type=AVC msg=audit(1296684821.927:43873): avc:  denied  { getattr } for  pid=15273 comm="pyzor" path="/home/orion/.pyzor" dev=0:1c ino=12374237 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=dir
type=AVC msg=audit(1296684821.927:43874): avc:  denied  { getattr } for  pid=15273 comm="pyzor" path="/home/orion/.pyzor/servers" dev=0:1c ino=12374279 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=file
type=AVC msg=audit(1296684821.927:43875): avc:  denied  { read } for  pid=15273 comm="pyzor" name="servers" dev=0:1c ino=12374279 scontext=root:system_r:pyzor_t:s0 tcontext=system_u:object_r:nfs_t:s0 tclass=file

Version-Release number of selected component (if applicable):
selinux-policy-2.4.6-279.el5_5.2

Comment 1 Miroslav Grepl 2011-02-03 10:53:23 UTC
We treat pyzor/razor policy as spamc_t policy in RHEL6 and we have


tunable_policy(`use_nfs_home_dirs',`
    fs_manage_nfs_dirs(spamc_t)
    fs_manage_nfs_files(spamc_t)
    fs_manage_nfs_symlinks(spamc_t)
')

tunable_policy(`use_samba_home_dirs',`
    fs_manage_cifs_dirs(spamc_t)
    fs_manage_cifs_files(spamc_t)
    fs_manage_cifs_symlinks(spamc_t)
')

I will add these rules for pyzor/razor policy to RHEL5. I mean

tunable_policy(`use_nfs_home_dirs',`
    fs_manage_nfs_dirs(pyzor_t)
    ..
')

tunable_policy(`use_samba_home_dirs',`
    fs_manage_cifs_dirs(pyzor_t)
    ..
')

Comment 3 Miroslav Grepl 2011-03-01 17:08:05 UTC
Fixed in selinux-policy-2.4.6-301.el5

Comment 6 errata-xmlrpc 2011-07-21 09:19:44 UTC
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 7 errata-xmlrpc 2011-07-21 11:56:05 UTC
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.