Bug 812094 - SELinux is preventing /usr/bin/totem-video-thumbnailer from 'setattr' accesses on the sock_file socket-4322-1804289383.
Summary: SELinux is preventing /usr/bin/totem-video-thumbnailer from 'setattr' accesse...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 17
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:c2aede47e45d9effad98006de94...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-04-12 18:15 UTC by Mirco Tischler
Modified: 2012-04-18 23:07 UTC (History)
3 users (show)

Fixed In Version: selinux-policy-3.10.0-116.fc17
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-04-18 23:07:43 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Mirco Tischler 2012-04-12 18:15:06 UTC
libreport version: 2.0.10
executable:     /usr/bin/python
hashmarkername: setroubleshoot
kernel:         3.3.0-8.fc17.x86_64
time:           Do 12 Apr 2012 20:12:56 CEST

description:
:SELinux is preventing /usr/bin/totem-video-thumbnailer from 'setattr' accesses on the sock_file socket-4322-1804289383.
:
:*****  Plugin catchall (100. confidence) suggests  ***************************
:
:If sie denken, dass totem-video-thumbnailer standardmässig erlaubt sein sollte, setattr Zugriff auf socket-4322-1804289383 sock_file zu erhalten.
:Then sie sollten dies als Fehler melden.
:Um diesen Zugriff zu erlauben, können Sie ein lokales Richtlinien-Modul erstellen.
:Do
:zugriff jetzt erlauben, indem Sie die nachfolgenden Befehle ausführen:
:# grep totem-video-thu /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:xdm_tmp_t:s0
:Target Objects                socket-4322-1804289383 [ sock_file ]
:Source                        totem-video-thu
:Source Path                   /usr/bin/totem-video-thumbnailer
:Port                          <Unbekannt>
:Host                          (removed)
:Source RPM Packages           totem-3.4.0-1.fc17.x86_64
:Target RPM Packages           
:Policy RPM                    selinux-policy-3.10.0-110.fc17.noarch
:Selinux Enabled               True
:Policy Type                   targeted
:Enforcing Mode                Permissive
:Host Name                     (removed)
:Platform                      Linux (removed) 3.3.0-8.fc17.x86_64 #1 SMP Thu Mar 29
:                              18:18:26 UTC 2012 x86_64 x86_64
:Alert Count                   1
:First Seen                    Do 12 Apr 2012 20:10:00 CEST
:Last Seen                     Do 12 Apr 2012 20:10:00 CEST
:Local ID                      d5f9ff37-f6ea-4136-a355-24c7b7139b55
:
:Raw Audit Messages
:type=AVC msg=audit(1334254200.611:335): avc:  denied  { setattr } for  pid=4322 comm="totem-video-thu" name="socket-4322-1804289383" dev="tmpfs" ino=3135140 scontext=unconfined_u:unconfined_r:thumb_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:xdm_tmp_t:s0 tclass=sock_file
:
:
:type=SYSCALL msg=audit(1334254200.611:335): arch=x86_64 syscall=chmod success=yes exit=0 a0=aee7a0 a1=1ff a2=1 a3=7fffccd25b8c items=0 ppid=1337 pid=4322 auid=1000 uid=1000 gid=1000 euid=1000 suid=1000 fsuid=1000 egid=1000 sgid=1000 fsgid=1000 tty=(none) ses=2 comm=totem-video-thu exe=/usr/bin/totem-video-thumbnailer subj=unconfined_u:unconfined_r:thumb_t:s0-s0:c0.c1023 key=(null)
:
:Hash: totem-video-thu,thumb_t,xdm_tmp_t,sock_file,setattr
:
:audit2allowunable to open /sys/fs/selinux/policy:  Permission denied
:
:
:audit2allow -Runable to open /sys/fs/selinux/policy:  Permission denied
:
:

Comment 1 Daniel Walsh 2012-04-12 21:13:53 UTC
Do you know if this tmp_t file was owned by totem or xdm?

Comment 2 Mirco Tischler 2012-04-13 13:09:30 UTC
If you mean file permissions, the file is owned by me, i.e. the user who used nautilus to browse to the directory containing the video files and thus triggering the execution of totem-video-thumbnailer.

What I probably should have added in the first place, there are followup alerts for write and remove_name accesses.

Also, this is 100% reproducible. I just have to create a new video file and browse to the directory containing it to trigger this.

Comment 3 Daniel Walsh 2012-04-13 16:07:53 UTC
Ok if it creates the socket than that is good.  I have checked in a fix to allow thumbnailers to create sockets in directories created by gdm.

selinux-policy-3.10.0-114.fc17.noarch

Comment 4 Mirco Tischler 2012-04-13 20:22:41 UTC
Are you sure this is the right build? I downloaded it from koji and it doesn't fix the issue. But koji says it was build this morning, so before Comment 2 and there is no mention of the change in the changelog?

Comment 5 Daniel Walsh 2012-04-13 20:42:27 UTC
Maybe not.  Lets say it is fixed in selinux-policy-3.10.0-114.fc17.noarch

You could check if the fix was supposed to be in -114

grep -r xserver_xdm_tmp_filetrans /usr/share/selinux/devel/

Comment 6 Mirco Tischler 2012-04-13 21:01:45 UTC
That comes up empty.

Comment 7 Miroslav Grepl 2012-04-16 06:17:04 UTC
It is going to be fixed in selinux-policy-3.10.0-115.fc17

Comment 8 Fedora Update System 2012-04-16 21:28:25 UTC
selinux-policy-3.10.0-116.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/selinux-policy-3.10.0-116.fc17

Comment 9 Mirco Tischler 2012-04-18 14:43:49 UTC
116 fixes the problem. However, one related AVC still comes up, where totem-video-thumbnailer asks for setattr on the parent directory /tmp/at-spi2. I didn't realize this wasn't a duplicate of the originally reported message until now. Here's the audit line:

type=AVC msg=audit(1334757947.372:154): avc:  denied  { setattr } for  pid=5280 comm="totem-video-thu" name="at-spi2" dev="tmpfs" ino=85909 scontext=unconfined_u:unconfined_r:thumb_t:s0-s0:c0.c1023 tcontext=system_u:object_r:xdm_tmp_t:s0 tclass=dir

Comment 10 Daniel Walsh 2012-04-18 20:50:31 UTC
Did everything work fine in enforcing mode, I guess we could dontaudit this one.

Comment 11 Fedora Update System 2012-04-18 23:07:43 UTC
selinux-policy-3.10.0-116.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.


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