Bug 1164473 - SELinux is preventing /usr/bin/totem-video-thumbnailer from 'create' accesses on the file orcexec.rfKPD2.
Summary: SELinux is preventing /usr/bin/totem-video-thumbnailer from 'create' accesses...
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: orc
Version: 23
Hardware: x86_64
OS: Unspecified
low
low
Target Milestone: ---
Assignee: Fabian Deutsch
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:bccb9e92dfa1d46245b68e20f9d...
: 1281541 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-11-15 16:36 UTC by Dawid Zamirski
Modified: 2023-09-14 02:50 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-12-20 12:57:08 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Dawid Zamirski 2014-11-15 16:36:46 UTC
Description of problem:
SELinux is preventing /usr/bin/totem-video-thumbnailer from 'create' accesses on the file orcexec.rfKPD2.

*****  Plugin catchall (100. confidence) suggests   **************************

If you believe that totem-video-thumbnailer should be allowed create access on the orcexec.rfKPD2 file 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 appsrc0:src /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                unconfined_u:unconfined_r:thumb_t:s0-s0:c0.c1023
Target Context                unconfined_u:object_r:user_home_dir_t:s0
Target Objects                orcexec.rfKPD2 [ file ]
Source                        appsrc0:src
Source Path                   /usr/bin/totem-video-thumbnailer
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           totem-3.14.0-1.fc21.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.13.1-92.fc21.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 3.17.2-300.fc21.x86_64 #1 SMP Thu
                              Oct 30 19:23:48 UTC 2014 x86_64 x86_64
Alert Count                   2
First Seen                    2014-11-15 11:35:54 EST
Last Seen                     2014-11-15 11:35:55 EST
Local ID                      4b415b3a-2e85-4785-8053-52454249a349

Raw Audit Messages
type=AVC msg=audit(1416069355.240:311): avc:  denied  { create } for  pid=4398 comm="appsrc0:src" name="orcexec.rfKPD2" scontext=unconfined_u:unconfined_r:thumb_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_dir_t:s0 tclass=file permissive=0


type=SYSCALL msg=audit(1416069355.240:311): arch=x86_64 syscall=open success=no exit=EACCES a0=7ff6bc001f40 a1=c2 a2=180 a3=524680 items=0 ppid=4329 pid=4398 auid=1000 uid=1001 gid=1001 euid=1001 suid=1001 fsuid=1001 egid=1001 sgid=1001 fsgid=1001 tty=pts0 ses=1 comm=appsrc0:src exe=/usr/bin/totem-video-thumbnailer subj=unconfined_u:unconfined_r:thumb_t:s0-s0:c0.c1023 key=(null)

Hash: appsrc0:src,thumb_t,user_home_dir_t,file,create

Version-Release number of selected component:
selinux-policy-3.13.1-92.fc21.noarch

Additional info:
reporter:       libreport-2.3.0
hashmarkername: setroubleshoot
kernel:         3.17.2-300.fc21.x86_64
type:           libreport

Comment 1 dac.override 2014-11-15 17:41:19 UTC
Fedora recently removed a patch that was included earlier with a modification that made liborc a bit more selinux friendly. It basically created a directory with a fixed name in the home directory (allowing us to use name-based file type transitions for this content), with the randomly named file inside.

The patch was not to the satisfaction of upstream and it was removed from fedora as well recently, as a result now causing issues again

I contacted the author of the patch and put him in contact with liborc upstream to find a way to deal with this. We came close but then patch author bailed (probably ran out of patience or did not think it was compelling reason enough)

What we did achieve however was that now orc first tries to create this file in $XDG_RUNTIME_DIR, if that is not permitted it tries $HOME and if that is not permitted it resorts to "process execmem" or fails

So i suppose if one allows programs that use liborc to manage and mmap files in $XDG_RUNTIME_DIR, that it will use that instead of $HOME. (for failover one may want to allow the same for $HOME)

Comment 2 Daniel Walsh 2014-11-18 16:30:02 UTC
Having it created in /run is a much better solution.  The backup should probably be in  ~/cache

 $XDG_CACHE_HOME defines the base directory relative to which user specific non-essential data files should be stored. If $XDG_CACHE_HOME is either not set or empty, a default equal to $HOME/.cache should be used.

Comment 3 Daniel Walsh 2014-11-18 16:35:06 UTC
  matchpathcon /run/user/3267/
/run/user/3267	system_u:object_r:user_tmp_t:s0

sesearch -T -s thumb_t -t user_tmp_t -C
Found 3 semantic te rules:
   type_transition thumb_t user_tmp_t : file thumb_tmp_t; 
   type_transition thumb_t user_tmp_t : dir thumb_tmp_t; 
   type_transition thumb_t user_tmp_t : sock_file thumb_tmp_t; 


BTW This is allowed in the current policy.

Comment 4 dac.override 2014-11-18 16:38:44 UTC
(In reply to Daniel Walsh from comment #2)
> Having it created in /run is a much better solution.  The backup should
> probably be in  ~/cache
> 
>  $XDG_CACHE_HOME defines the base directory relative to which user specific
> non-essential data files should be stored. If $XDG_CACHE_HOME is either not
> set or empty, a default equal to $HOME/.cache should be used.

I invite you to take this up with the upstream orc maintainer (#orc)

Comment 6 Daniel Walsh 2014-11-21 16:07:46 UTC
Any reason $HOME happens before /tmp?

Comment 7 Fedora End Of Life 2015-11-04 14:51:38 UTC
This message is a reminder that Fedora 21 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 21. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '21'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 21 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 8 Fabian Deutsch 2015-11-23 08:29:10 UTC
*** Bug 1281541 has been marked as a duplicate of this bug. ***

Comment 9 Lukas Vrabec 2015-11-23 09:10:25 UTC
Any update here?

Comment 10 Wim Taymans 2016-08-10 09:50:27 UTC
What is left to be done? does it work correctly now with the upstream fixes?

Comment 11 Fedora End Of Life 2016-11-24 11:17:18 UTC
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '23'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 23 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 12 Fedora End Of Life 2016-12-20 12:57:08 UTC
Fedora 23 changed to end-of-life (EOL) status on 2016-12-20. Fedora 23 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 13 Red Hat Bugzilla 2023-09-14 02:50:55 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 1000 days


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