This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 904375 - SELinux is preventing /usr/sbin/xl2tpd from 'read' accesses on the file nm-xl2tpd.conf.1882.
SELinux is preventing /usr/sbin/xl2tpd from 'read' accesses on the file nm-xl...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
18
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
abrt_hash:45405fbd9fb5f4f939a88c660e1...
: Reopened
: 907012 907013 907015 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-01-26 08:52 EST by Айфф
Modified: 2013-03-07 05:09 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-03-07 05:09:46 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
# ausearch -m avc -su l2tpd_t (1.80 KB, application/octet-stream)
2013-02-04 06:54 EST, Айфф
no flags Details

  None (edit)
Description Айфф 2013-01-26 08:52:11 EST
Description of problem:
Пытался подключится к интернету при помощи NetworkManager-l2tp.

Additional info:
hashmarkername: setroubleshoot
kernel:         3.7.2-204.fc18.x86_64
type:           libreport
Comment 1 Miroslav Grepl 2013-01-28 06:01:01 EST
Could you also attach AVC msg which you are getting? Did you submit it with this report?
Comment 2 Айфф 2013-01-28 06:45:48 EST
SELinux is preventing /usr/sbin/xl2tpd from read access on the file nm-xl2tpd.conf.2172.

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

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

Additional Information:
Source Context                system_u:system_r:l2tpd_t:s0
Target Context                system_u:object_r:NetworkManager_var_run_t:s0
Target Objects                nm-xl2tpd.conf.2172 [ file ]
Source                        xl2tpd
Source Path                   /usr/sbin/xl2tpd
Port                          <Unknown>
Host                          localhost.localdomain
Source RPM Packages           xl2tpd-1.3.1-10.fc18.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.11.1-73.fc18.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     localhost.localdomain
Platform                      Linux localhost.localdomain 3.7.4-204.fc18.x86_64
                              #1 SMP Wed Jan 23 16:44:29 UTC 2013 x86_64 x86_64
Alert Count                   1
First Seen                    2013-01-28 14:42:06 FET
Last Seen                     2013-01-28 14:42:06 FET
Local ID                      31718065-e191-45c9-bacc-4b9e64c704e2

Raw Audit Messages
type=AVC msg=audit(1359373326.439:335): avc:  denied  { read } for  pid=2189 comm="xl2tpd" name="nm-xl2tpd.conf.2172" dev="tmpfs" ino=101873 scontext=system_u:system_r:l2tpd_t:s0 tcontext=system_u:object_r:NetworkManager_var_run_t:s0 tclass=file


type=SYSCALL msg=audit(1359373326.439:335): arch=x86_64 syscall=open success=no exit=EACCES a0=61e028 a1=0 a2=1b6 a3=238 items=0 ppid=2172 pid=2189 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 ses=4294967295 tty=(none) comm=xl2tpd exe=/usr/sbin/xl2tpd subj=system_u:system_r:l2tpd_t:s0 key=(null)

Hash: xl2tpd,l2tpd_t,NetworkManager_var_run_t,file,read

audit2allow

#============= l2tpd_t ==============
allow l2tpd_t NetworkManager_var_run_t:file read;

audit2allow -R

#============= l2tpd_t ==============
allow l2tpd_t NetworkManager_var_run_t:file read;
Comment 3 Daniel Walsh 2013-01-28 10:53:09 EST
Looks like there is a pretty good connection between the apps.
Comment 4 Daniel Walsh 2013-01-28 11:12:09 EST
Fixed in git.
Comment 5 Miroslav Grepl 2013-01-28 12:18:25 EST
Backported.
Comment 6 Fedora Update System 2013-01-31 08:19:12 EST
selinux-policy-3.11.1-74.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/selinux-policy-3.11.1-74.fc18
Comment 7 Fedora Update System 2013-02-01 11:39:55 EST
Package selinux-policy-3.11.1-74.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.11.1-74.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-1693/selinux-policy-3.11.1-74.fc18
then log in and leave karma (feedback).
Comment 8 Айфф 2013-02-01 12:19:27 EST
Не получается.

# su -c 'yum update --enablerepo=updates-testing selinux-policy-3.11.1-74.fc18'
Загружены модули: langpacks, presto
Совпадений с selinux-policy-3.11.1-74.fc18 не найдено.
Пакета с названием selinux-policy-3.11.1-74.fc18 не найдено.
Пакетов, отмеченных для обновления, нет.
Comment 9 Айфф 2013-02-02 11:48:23 EST
Установил selinux-policy-3.11.1-74.fc18, но не работает.

1) SELinux is preventing /usr/libexec/nm-l2tp-service from name_bind access on the udp_socket .
2) SELinux is preventing /usr/sbin/pppd from read access on the file nm-ppp-options.xl2tpd.6974.
3) SELinux is preventing /usr/libexec/nm-l2tp-service from using the signal access on a process.
4) SELinux is preventing /usr/libexec/nm-l2tp-service from using the sigkill access on a process.
Comment 10 Miroslav Grepl 2013-02-04 06:07:24 EST
*** Bug 907012 has been marked as a duplicate of this bug. ***
Comment 11 Miroslav Grepl 2013-02-04 06:07:29 EST
*** Bug 907013 has been marked as a duplicate of this bug. ***
Comment 12 Miroslav Grepl 2013-02-04 06:07:34 EST
*** Bug 907015 has been marked as a duplicate of this bug. ***
Comment 13 Miroslav Grepl 2013-02-04 06:16:41 EST
Could you also attach AVC msgs?

ausearch -m avc -su l2tpd_t
Comment 14 Miroslav Grepl 2013-02-04 06:18:26 EST
Also I added some fixes.

commit 4c752571162cc4cb26063ff4ee0bae4a6a66b509
Author: Miroslav Grepl <mgrepl@redhat.com>
Date:   Mon Feb 4 12:16:39 2013 +0100

    Allow l2tpd_t to all signal perms
Comment 15 Айфф 2013-02-04 06:54:09 EST
Created attachment 692689 [details]
# ausearch -m avc -su l2tpd_t
Comment 16 Fedora Update System 2013-02-07 21:24:39 EST
selinux-policy-3.11.1-74.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 17 Айфф 2013-03-06 12:26:03 EST
Проблема повторилась. Установлен selinux-policy-3.11.1-82.fc18.
Comment 18 Айфф 2013-03-06 12:27:05 EST
Пытался использовать NetworkManager-l2tp.

Package: (null)
OS Release: Fedora release 18 (Spherical Cow)
Comment 19 Miroslav Grepl 2013-03-07 05:09:46 EST
#============= l2tpd_t ==============
#!!!! This avc is allowed in the current policy

allow l2tpd_t NetworkManager_var_run_t:file read;

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