Bug 591157

Summary: SELinux is preventing /opt/teamviewer/teamviewer/5/wine/bin/wine-preloader from loading /opt/teamviewer/teamviewer/5/wine/drive_c/Program Files/TeamViewer/Version5/TeamViewer.exe which requires text relocation.
Product: [Fedora] Fedora Reporter: Onuralp SEZER <thunderbirdtr>
Component: selinux-policyAssignee: Daniel Walsh <dwalsh>
Status: CLOSED CANTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 12CC: aaron-kuo, abhilash6399, Abus56rus, bjmeany, chris.partezana, claudio, colakoglu.omerfaruk, csbucur, dwalsh, egzon_salihi, fedora13lab, frederic.berard, inf.marcos, javier_santos30, kide65, krishnandu.sarkar, Laray80, mail.dsp, manitha, mgrepl, rehol3, rianby64, rikyinformation, rodrigoatique, ronaldcanete, spamer-1337, sparsa4, srinivasa.nallapati, s_rzayev, ssabcew, valent.turkovic, wolfgang, zozo_sarv2000
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard: setroubleshoot_trace_hash:68c42d3e4d6db4e53bd3e1e28485cd4be8ff513cfc0c2a721530a37451225596
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-05-11 15:16:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Onuralp SEZER 2010-05-11 15:09:26 UTC
Summary:

SELinux is preventing /opt/teamviewer/teamviewer/5/wine/bin/wine-preloader from
loading /opt/teamviewer/teamviewer/5/wine/drive_c/Program
Files/TeamViewer/Version5/TeamViewer.exe which requires text relocation.

Detailed Description:

The TeamViewer.exe application attempted to load
/opt/teamviewer/teamviewer/5/wine/drive_c/Program
Files/TeamViewer/Version5/TeamViewer.exe which requires text relocation. This is
a potential security problem. Most libraries do not need this permission.
Libraries are sometimes coded incorrectly and request this permission. The
SELinux Memory Protection Tests
(http://people.redhat.com/drepper/selinux-mem.html) web page explains how to
remove this requirement. You can configure SELinux temporarily to allow
/opt/teamviewer/teamviewer/5/wine/drive_c/Program
Files/TeamViewer/Version5/TeamViewer.exe to use relocation as a workaround,
until the library is fixed. Please file a bug report.

Allowing Access:

If you trust /opt/teamviewer/teamviewer/5/wine/drive_c/Program
Files/TeamViewer/Version5/TeamViewer.exe to run correctly, you can change the
file context to textrel_shlib_t. "chcon -t textrel_shlib_t
'/opt/teamviewer/teamviewer/5/wine/drive_c/Program
Files/TeamViewer/Version5/TeamViewer.exe'" You must also change the default file
context files on the system in order to preserve them even on a full relabel.
"semanage fcontext -a -t textrel_shlib_t
'/opt/teamviewer/teamviewer/5/wine/drive_c/Program.Files/TeamViewer/Version5/TeamViewer.exe'"

Fix Command:

chcon -t textrel_shlib_t '/opt/teamviewer/teamviewer/5/wine/drive_c/Program
Files/TeamViewer/Version5/TeamViewer.exe'

Additional Information:

Source Context                unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1
                              023
Target Context                system_u:object_r:usr_t:s0
Target Objects                /opt/teamviewer/teamviewer/5/wine/drive_c/Program
                              Files/TeamViewer/Version5/TeamViewer.exe [ file ]
Source                        TeamViewer.exe
Source Path                   /opt/teamviewer/teamviewer/5/wine/bin/wine-
                              preloader
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           teamviewer5-5.0-1
Target RPM Packages           teamviewer5-5.0-1
Policy RPM                    selinux-policy-3.6.32-113.fc12
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   allow_execmod
Host Name                     (removed)
Platform                      Linux (removed) 2.6.32.11-99.fc12.i686
                              #1 SMP Mon Apr 5 16:32:08 EDT 2010 i686 i686
Alert Count                   4
First Seen                    Tue 11 May 2010 06:06:40 PM EEST
Last Seen                     Tue 11 May 2010 06:06:40 PM EEST
Local ID                      c2d9bb59-78ce-448b-b8d5-0839f651bbf9
Line Numbers                  

Raw Audit Messages            

node=(removed) type=AVC msg=audit(1273590400.827:81): avc:  denied  { execmod } for  pid=3166 comm="TeamViewer.exe" path=2F6F70742F7465616D7669657765722F7465616D7669657765722F352F77696E652F64726976655F632F50726F6772616D2046696C65732F5465616D5669657765722F56657273696F6E352F5465616D5669657765722E657865 dev=sda6 ino=660758 scontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 tcontext=system_u:object_r:usr_t:s0 tclass=file

node=(removed) type=SYSCALL msg=audit(1273590400.827:81): arch=40000003 syscall=125 success=no exit=-13 a0=7b9000 a1=1000 a2=5 a3=7b9000 items=0 ppid=1 pid=3166 auid=500 uid=500 gid=500 euid=500 suid=500 fsuid=500 egid=500 sgid=500 fsgid=500 tty=(none) ses=1 comm="TeamViewer.exe" exe="/opt/teamviewer/teamviewer/5/wine/bin/wine-preloader" subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  allow_execmod,TeamViewer.exe,unconfined_t,usr_t,file,execmod
audit2allow suggests:

#============= unconfined_t ==============
#!!!! This avc can be allowed using the boolean 'allow_execmod'

allow unconfined_t usr_t:file execmod;

Comment 1 Daniel Walsh 2010-05-11 15:16:13 UTC
Are you running F12 or F13?

Just set the allow_execmod boolean and it will work.

# setsebool -P allow_execmod 1

Comment 2 Onuralp SEZER 2010-05-11 15:24:20 UTC
I'm using Fedora 12 and thanks
I'm trying now ..

Comment 3 Onuralp SEZER 2010-05-11 15:30:00 UTC
And May I asking something about using yum sometime it's stop downloading and I see 

Example : 



(10/56) : xxxx.rpm (%20) 45% [====         ] 0 B/s | 20 MB    438534594759:00 ETA

Like that 

Why did it do like that sometime ? 

Thanks you working for Team Viewer Problem

Comment 4 Onuralp SEZER 2010-05-11 15:36:41 UTC
And May I asking something about using yum sometime it's stop downloading and I see 

Example : 



(10/56) : xxxx.rpm (%20) 45% [====         ] 0 B/s | 20 MB    438534594759:00 ETA

Like that 

Why did it do like that sometime ? 

Thanks you working for Team Viewer Problem

Comment 5 Daniel Walsh 2010-05-11 17:35:51 UTC
I think this indicates a loss of network connectivity.  I usually just stop and restart the yum.

Comment 6 Onuralp SEZER 2010-05-11 18:22:56 UTC
so do I

I was stop and restart too 

thank you and I fix my problem thank you so much again