File: snappy.fc

package info (click to toggle)
snapd 2.72-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 80,412 kB
  • sloc: sh: 16,506; ansic: 16,211; python: 11,213; makefile: 1,919; exp: 190; awk: 58; xml: 22
file content (60 lines) | stat: -rw-r--r-- 3,247 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# This file is part of snapd-selinux
# Skeleton derived from Fedora selinux-policy, Copyright (C) 2016 Red Hat, Inc.
# Copyright (C) 2016 Neal Gompa
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU Library General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.


HOME_DIR/snap(/.*)?			gen_context(system_u:object_r:snappy_home_t,s0)
/root/snap(/.*)?			gen_context(system_u:object_r:snappy_home_t,s0)

/usr/bin/snap			--	gen_context(system_u:object_r:snappy_cli_exec_t,s0)
/usr/bin/snapctl		--	gen_context(system_u:object_r:snappy_cli_exec_t,s0)

# TODO add policy for snapd-apparmor?
ifdef(`distro_redhat',`
/usr/libexec/snapd/snapctl		--	gen_context(system_u:object_r:snappy_cli_exec_t,s0)
/usr/libexec/snapd/snap-confine		--	gen_context(system_u:object_r:snappy_confine_exec_t,s0)
/usr/libexec/snapd/snap-update-ns		--	gen_context(system_u:object_r:snappy_mount_exec_t,s0)
/usr/libexec/snapd/snap-discard-ns		--	gen_context(system_u:object_r:snappy_mount_exec_t,s0)
/usr/libexec/snapd/.*		--	gen_context(system_u:object_r:snappy_exec_t,s0)
/etc/sysconfig/snapd		-- 	gen_context(system_u:object_r:snappy_config_t,s0)
/usr/lib/systemd/system/snapd.* --	gen_context(system_u:object_r:snappy_unit_file_t,s0)
')

ifdef(`distro_debian',`
/usr/lib/snapd/snapctl		--	gen_context(system_u:object_r:snappy_cli_exec_t,s0)
/usr/lib/snapd/snap-confine		--	gen_context(system_u:object_r:snappy_confine_exec_t,s0)
/usr/lib/snapd/snap-update-ns		--	gen_context(system_u:object_r:snappy_mount_exec_t,s0)
/usr/lib/snapd/snap-discard-ns		--	gen_context(system_u:object_r:snappy_mount_exec_t,s0)
/usr/lib/snapd/.*  		--	gen_context(system_u:object_r:snappy_exec_t,s0)
/etc/default/snapd		-- 	gen_context(system_u:object_r:snappy_config_t,s0)
/lib/systemd/system/snapd.* 	--	gen_context(system_u:object_r:snappy_unit_file_t,s0)
')

/var/run/snapd(/.*)?	        gen_context(system_u:object_r:snappy_var_run_t,s0)
/var/run/snapd\.socket 		-s	gen_context(system_u:object_r:snappy_var_run_t,s0)
/var/run/snapd-snap\.socket 	-s	gen_context(system_u:object_r:snappy_var_run_t,s0)
/var/lib/snapd(/.*)?			gen_context(system_u:object_r:snappy_var_lib_t,s0)
/var/cache/snapd(/.*)?			gen_context(system_u:object_r:snappy_var_cache_t,s0)
/var/snap(/.*)?				gen_context(system_u:object_r:snappy_var_t,s0)
# on openSUSE, snaps are mounted under /snap
ifdef(`distro_opensuse',`
/snap(/.*)?					gen_context(system_u:object_r:snappy_var_lib_t,s0)
')

/run/snapd(/.*)?	        gen_context(system_u:object_r:snappy_var_run_t,s0)
/run/snapd\.socket 		-s	gen_context(system_u:object_r:snappy_var_run_t,s0)
/run/snapd-snap\.socket 	-s	gen_context(system_u:object_r:snappy_var_run_t,s0)