Bug 754883

Summary: SELinux is preventing /usr/sbin/useradd from 'write' accesses on the dossier xguest.
Product: [Fedora] Fedora Reporter: Luya Tshimbalanga <luya>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 16CC: dominick.grift, dwalsh, mgrepl
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:76d4a23200523af8024dd864bd7187aacc3e0070ea10461df53cd080e4b59263
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-11-18 03:13:06 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Luya Tshimbalanga 2011-11-18 03:11:52 UTC
libreport version: 2.0.6
executable:     /usr/bin/python
hashmarkername: setroubleshoot
kernel:         3.1.1-1.fc16.x86_64
reason:         SELinux is preventing /usr/sbin/useradd from 'write' accesses on the dossier xguest.
time:           Thu Nov 17 19:11:36 2011

description:
:SELinux is preventing /usr/sbin/useradd from 'write' accesses on the dossier xguest.
:
:*****  Plugin catchall_labels (83.8 confidence) suggests  ********************
:
:If vous souhaitez autoriser useradd à accéder à write sur xguest directory
:Then you need to change the label on xguest
:Do
:# semanage fcontext -a -t FILE_TYPE 'xguest'
:where FILE_TYPE is one of the following: user_home_type, pcscd_var_run_t, home_root_t, user_home_dir_t, httpd_user_content_type, mail_spool_t, etc_t, httpd_user_script_exec_type. 
:Then execute: 
:restorecon -v 'xguest'
:
:
:*****  Plugin catchall (17.1 confidence) suggests  ***************************
:
:If you believe that useradd should be allowed write access on the xguest directory by default.
:Then you should report this as a bug.
:You can generate a local policy module to allow this access.
:Do
:allow this access for now by executing:
:# grep useradd /var/log/audit/audit.log | audit2allow -M mypol
:# semodule -i mypol.pp
:
:Additional Information:
:Source Context                system_u:system_r:useradd_t:s0-s0:c0.c1023
:Target Context                system_u:object_r:var_lib_t:s0
:Target Objects                xguest [ dir ]
:Source                        useradd
:Source Path                   /usr/sbin/useradd
:Port                          <Inconnu>
:Host                          (removed)
:Source RPM Packages           shadow-utils-4.1.4.3-10.fc16
:Target RPM Packages           
:Policy RPM                    selinux-policy-3.10.0-55.fc16
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Enforcing
:Host Name                     (removed)
:Platform                      Linux (removed) 3.1.1-1.fc16.x86_64 #1 SMP
:                              Fri Nov 11 21:47:56 UTC 2011 x86_64 x86_64
:Alert Count                   1
:First Seen                    jeu 17 nov 2011 19:10:49 PST
:Last Seen                     jeu 17 nov 2011 19:10:49 PST
:Local ID                      804006e4-daa1-4fc0-837e-124bb0984f38
:
:Raw Audit Messages
:type=AVC msg=audit(1321585849.996:272): avc:  denied  { write } for  pid=11541 comm="useradd" name="xguest" dev=dm-1 ino=2885943 scontext=system_u:system_r:useradd_t:s0-s0:c0.c1023 tcontext=system_u:object_r:var_lib_t:s0 tclass=dir
:
:
:type=SYSCALL msg=audit(1321585849.996:272): arch=x86_64 syscall=mkdir success=no exit=EACCES a0=7fff323a6f30 a1=0 a2=0 a3=65726373662f7274 items=0 ppid=11540 pid=11541 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=useradd exe=/usr/sbin/useradd subj=system_u:system_r:useradd_t:s0-s0:c0.c1023 key=(null)
:
:Hash: useradd,useradd_t,var_lib_t,dir,write
:
:audit2allow
:
:#============= useradd_t ==============
:#!!!! The source type 'useradd_t' can write to a 'dir' of the following types:
:# user_home_type, pcscd_var_run_t, home_root_t, user_home_dir_t, httpd_user_content_type, mail_spool_t, etc_t, httpd_user_script_exec_type
:
:allow useradd_t var_lib_t:dir write;
:
:audit2allow -R
:
:#============= useradd_t ==============
:#!!!! The source type 'useradd_t' can write to a 'dir' of the following types:
:# user_home_type, pcscd_var_run_t, home_root_t, user_home_dir_t, httpd_user_content_type, mail_spool_t, etc_t, httpd_user_script_exec_type
:
:allow useradd_t var_lib_t:dir write;
:

Comment 1 Luya Tshimbalanga 2011-11-18 03:13:06 UTC

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