This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1278990 - SELinux is preventing /usr/sbin/setfiles from 'read' accesses on the file /etc/tor/torsocks.conf.
SELinux is preventing /usr/sbin/setfiles from 'read' accesses on the file /et...
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
x86_64 Unspecified
low Severity low
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2015-11-06 18:31 EST by Айфф
Modified: 2016-07-19 16:56 EDT (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-07-19 16:56:22 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
jamesbdonovan: needinfo-

Attachments (Terms of Use)

  None (edit)
Description Айфф 2015-11-06 18:31:05 EST
Description of problem:
Updating the system:
$ torify dnf upgrade
SELinux is preventing /usr/sbin/setfiles from 'read' accesses on the file /etc/tor/torsocks.conf.

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

If вы считаете, что setfiles следует разрешить доступ read к torsocks.conf file по умолчанию.
Then рекомендуется создать отчет об ошибке.
Чтобы разрешить доступ, можно создать локальный модуль политики.
чтобы разрешить доступ, выполните:
# grep restorecon /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                unconfined_u:unconfined_r:setfiles_t:s0-s0:c0.c102
Target Context                system_u:object_r:tor_etc_t:s0
Target Objects                /etc/tor/torsocks.conf [ file ]
Source                        restorecon
Source Path                   /usr/sbin/setfiles
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           policycoreutils-2.3-18.fc22.x86_64
Target RPM Packages           torsocks-2.1.0-1.fc22.x86_64
Policy RPM                    selinux-policy-3.13.1-128.16.fc22.noarch selinux-
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 4.2.3-200.fc22.x86_64 #1 SMP Thu
                              Oct 8 03:23:55 UTC 2015 x86_64 x86_64
Alert Count                   3
First Seen                    2015-11-07 02:27:04 MSK
Last Seen                     2015-11-07 02:27:08 MSK
Local ID                      c2f16d84-f86b-4df3-91da-87f8f5cc36f1

Raw Audit Messages
type=AVC msg=audit(1446852428.287:562): avc:  denied  { read } for  pid=27409 comm="restorecon" name="torsocks.conf" dev="dm-2" ino=788434 scontext=unconfined_u:unconfined_r:setfiles_t:s0-s0:c0.c1023 tcontext=system_u:object_r:tor_etc_t:s0 tclass=file permissive=0

type=SYSCALL msg=audit(1446852428.287:562): arch=x86_64 syscall=open success=no exit=EACCES a0=7f925b7d0e5b a1=0 a2=1b6 a3=ac items=0 ppid=26789 pid=27409 auid=1000 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=pts1 ses=1 comm=restorecon exe=/usr/sbin/setfiles subj=unconfined_u:unconfined_r:setfiles_t:s0-s0:c0.c1023 key=(null)

Hash: restorecon,setfiles_t,tor_etc_t,file,read

Version-Release number of selected component:

Additional info:
reporter:       libreport-2.6.3
hashmarkername: setroubleshoot
kernel:         4.2.3-200.fc22.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2015-11-11 03:18:13 EST
Does it happen only with torify? I am not able to reproduce it.
Comment 2 Daniel Walsh 2015-11-14 06:55:03 EST
Leaked file descriptor.
Comment 3 Miroslav Grepl 2015-11-20 07:47:48 EST
Yes but I would like to know if torify leaks fds.
Comment 4 Fedora End Of Life 2016-07-19 16:56:22 EDT
Fedora 22 changed to end-of-life (EOL) status on 2016-07-19. Fedora 22 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

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

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