Bug 608640 - SELinux is preventing /usr/bin/totem-video-thumbnailer "setrlimit" access .
SELinux is preventing /usr/bin/totem-video-thumbnailer "setrlimit" access .
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: selinux-policy (Show other bugs)
6.0
x86_64 Linux
medium Severity medium
: rc
: ---
Assigned To: Miroslav Grepl
Milos Malik
setroubleshoot_trace_hash:fb976057edb...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-06-28 07:19 EDT by Matěj Cepl
Modified: 2012-10-15 10:57 EDT (History)
5 users (show)

See Also:
Fixed In Version: selinux-policy-3.7.19-32.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-11-10 16:34:57 EST
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 Matěj Cepl 2010-06-28 07:19:43 EDT
When starting gnome-shell, I get a lot of errors in totem-video-thumbnailer


Souhrn:

SELinux is preventing /usr/bin/totem-video-thumbnailer "setrlimit" access .

Podrobný popis:

[totem-video-thu je v toleratním režimu (staff_execmem_t). Přístup byl
povolen.]

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

Povolení přístupu:

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.

Další informace:

Kontext zdroje                staff_u:staff_r:staff_execmem_t:s0-s0:c0.c1023
Kontext cíle                 staff_u:staff_r:staff_execmem_t:s0-s0:c0.c1023
Objekty cíle                 None [ process ]
Zdroj                         totem-video-thu
Cesta zdroje                  /usr/bin/totem-video-thumbnailer
Port                          <Neznámé>
Počítač                    (removed)
RPM balíčky zdroje          totem-2.28.6-1.el6
RPM balíčky cíle           
RPM politiky                  selinux-policy-3.7.19-27.el6
Selinux povolen               True
Typ politiky                  targeted
Vynucovací režim            Enforcing
Název zásuvného modulu     catchall
Název počítače            (removed)
Platforma                     Linux (removed) 2.6.32-37.el6.x86_64 #1
                              SMP Sun Jun 20 19:29:35 EDT 2010 x86_64 x86_64
Počet upozornění           6
Poprvé viděno               Po 28. červen 2010, 12:39:04 CEST
Naposledy viděno             Po 28. červen 2010, 12:39:25 CEST
Místní ID                   86e1ffc5-03df-4d44-8954-e45737916d07
Čísla řádků              

Původní zprávy auditu      

node=(removed) type=AVC msg=audit(1277721565.63:53823): avc:  denied  { setrlimit } for  pid=29023 comm="totem-video-thu" scontext=staff_u:staff_r:staff_execmem_t:s0-s0:c0.c1023 tcontext=staff_u:staff_r:staff_execmem_t:s0-s0:c0.c1023 tclass=process

node=(removed) type=SYSCALL msg=audit(1277721565.63:53823): arch=c000003e syscall=160 success=yes exit=73014444160 a0=0 a1=7fff95acef00 a2=d a3=1 items=0 ppid=28916 pid=29023 auid=500 uid=500 gid=500 euid=500 suid=500 fsuid=500 egid=500 sgid=500 fsgid=500 tty=pts6 ses=1 comm="totem-video-thu" exe="/usr/bin/totem-video-thumbnailer" subj=staff_u:staff_r:staff_execmem_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  catchall,totem-video-thu,staff_execmem_t,staff_execmem_t,process,setrlimit
audit2allow suggests:

#============= staff_execmem_t ==============
allow staff_execmem_t self:process setrlimit;
Comment 2 RHEL Product and Program Management 2010-06-28 07:42:52 EDT
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.
Comment 3 Daniel Walsh 2010-06-28 09:41:58 EDT
Should we just allow this for a confined user?  staff_t, user_t.  Since setrlimit can only lower priority if you do not have CAP_SYS_RESOURCE?
Comment 4 Stephen Smalley 2010-06-28 15:09:49 EDT
Only concern is if the confined user domain can transition to some privileged program domain and you are concerned about the confined user domain trying to induce a failure in the privileged program by first lowering the hard limits prior to exec'ing it.  That was the original rationale for the setrlimit and rlimitinh checks.
Comment 5 Daniel Walsh 2010-06-29 08:13:50 EDT
Should I add a boolean then.   users_can_setrlimit?
Comment 6 Daniel Walsh 2010-07-12 11:42:17 EDT
Miroslav,  Please add

## <desc>
## <p>
## Allow user processes to change their priority 
## </p>
## </desc>
gen_tunable(user_setrlimit, false)

And

	tunable_policy(`user_setrlimit',`
		allow $1_usertype self:process setrlimit;
	')

to 

template(`userdom_unpriv_user_template', `


And default this to true in booleans-targeted.conf
Comment 8 Miroslav Grepl 2010-07-14 10:26:18 EDT
Fixed in selinux-policy-3.7.19-32.el6.noarch
Comment 11 releng-rhel@redhat.com 2010-11-10 16:34:57 EST
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

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