summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2011-08-07 11:01:56 +0000
committerAnthony G. Basile <blueness@gentoo.org>2011-08-07 11:01:56 +0000
commit080532ba71382880a2a7aad5e0513c59108302a9 (patch)
tree63344027f2987e80638bba4e8cb1224e7267df08 /sec-policy
parentLeave setting -g and -O levels to user with debug build wrt #376895 (diff)
downloadhistorical-080532ba71382880a2a7aad5e0513c59108302a9.tar.gz
historical-080532ba71382880a2a7aad5e0513c59108302a9.tar.bz2
historical-080532ba71382880a2a7aad5e0513c59108302a9.zip
Improve policy style, do not require libs_use_ld_so
Package-Manager: portage-2.1.10.3/cvs/Linux x86_64
Diffstat (limited to 'sec-policy')
-rw-r--r--sec-policy/selinux-skype/ChangeLog8
-rw-r--r--sec-policy/selinux-skype/Manifest10
-rw-r--r--sec-policy/selinux-skype/files/fix-apps-skype-r3.patch120
-rw-r--r--sec-policy/selinux-skype/selinux-skype-2.20101213-r3.ebuild16
4 files changed, 149 insertions, 5 deletions
diff --git a/sec-policy/selinux-skype/ChangeLog b/sec-policy/selinux-skype/ChangeLog
index e3cfea461992..a2ca8e60dfcb 100644
--- a/sec-policy/selinux-skype/ChangeLog
+++ b/sec-policy/selinux-skype/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sec-policy/selinux-skype
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sec-policy/selinux-skype/ChangeLog,v 1.3 2011/06/04 18:10:53 blueness Exp $
+# $Header: /var/cvsroot/gentoo-x86/sec-policy/selinux-skype/ChangeLog,v 1.4 2011/08/07 11:01:56 blueness Exp $
+
+*selinux-skype-2.20101213-r3 (07 Aug 2011)
+
+ 07 Aug 2011; Anthony G. Basile <blueness@gentoo.org>
+ +files/fix-apps-skype-r3.patch, +selinux-skype-2.20101213-r3.ebuild:
+ Improve policy style, do not require libs_use_ld_so
04 Jun 2011; Anthony G. Basile <blueness@gentoo.org>
-selinux-skype-2.20101213.ebuild, -selinux-skype-2.20101213-r1.ebuild:
diff --git a/sec-policy/selinux-skype/Manifest b/sec-policy/selinux-skype/Manifest
index c9dfd7be3eac..721fd5cc20ab 100644
--- a/sec-policy/selinux-skype/Manifest
+++ b/sec-policy/selinux-skype/Manifest
@@ -4,14 +4,16 @@ Hash: SHA256
AUX add-apps-skype-r2.patch 3196 RMD160 1366b1a0f48ff1bacbd7693752a760810cad809b SHA1 3699e58ecf6c36335e8d6868454283fd8962ab58 SHA256 fdd50bf75b792c370efce61bbbf5ab94aa2b3396e6a05c8b3e4170093b5af2f5
AUX add-apps-skype.patch 2990 RMD160 6636b36593d30c25143f086bad6a3a3383656d47 SHA1 e302c2f125566cf566a266852db394fae09a7600 SHA256 eb5cdf5bacf23ac082fbdf8fbda2a7ad679672d991f2c866a41360da4a8813c0
AUX add-skype.patch 3597 RMD160 f813f810a5eba1d638b82b3ee17ec44745efa5d0 SHA1 4beca399f9bffbbbd470f89ac7fb323d0529bae6 SHA256 67f9085f20b6e7deceea815e02e45fe42aa6a4221e61fa07f0e7735b0ac42ca9
+AUX fix-apps-skype-r3.patch 3694 RMD160 0c62a28ac87122a336d3efab5395afea7698e7e5 SHA1 bb8894fca1861615089934a564ffdee6020eeb62 SHA256 79fe5ee443a44f98af35dbb904fb41b28359d81d2b87f49ad26deb6ee14adfe9
DIST refpolicy-2.20101213.tar.bz2 559450 RMD160 4858f792f4db5b179de6fb8419a626c29d59bdd3 SHA1 0e881e99b8950a358eadc44633551ca10f12eaee SHA256 b691ee8f6066cc19bb0d4384fe3be277d97d22e9d4ac2db0c252065e8c3535de
EBUILD selinux-skype-2.20101213-r2.ebuild 478 RMD160 2a756fbdbe104d523b760398e3729140c7bacab3 SHA1 c0398ab80c0c751811e7a2b0d41c8f1a157c2140 SHA256 f6b52fbcbfaf4295c634d767ec55b76b325860493eb9ab05b367371bb82e2f18
-MISC ChangeLog 1008 RMD160 dcc1ca4d48e3aba8789bf7750b70248ec560250d SHA1 5b4064246cb84d468aec4b151fdf8112de32f3d5 SHA256 0485f1bfc2764b6bb83244cb07823b260560392c81bf5734e69dccb99bf54e17
+EBUILD selinux-skype-2.20101213-r3.ebuild 481 RMD160 6615b5c1cfe796b18b275e00cca53c8dacb48792 SHA1 d96f4086772132637cdfdbc2313cb2623c9fb5eb SHA256 01befb92157de118d5e8b77a245dd8fe83cc636ded2151f499d1fed1588904b1
+MISC ChangeLog 1233 RMD160 1e5db76014f282e175437394261ebd3295f079f2 SHA1 7cc874d3b1f375b67a73d9d03ae49de0dcd013b5 SHA256 fc88945efe1dd4b162465b0fd747137dfc9980af8e47cf1145b520f3c6374078
MISC metadata.xml 229 RMD160 7be38657dc886f94d34da26afac854d1f600fa5c SHA1 cabb5d760e89f5420867a1e1b71e019dbc03745a SHA256 dd045a440e1dfe8b2e5eb751cf8f81178e21ae2b7916571824bf81faba81f762
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (GNU/Linux)
-iEYEAREIAAYFAk3qdTcACgkQl5yvQNBFVTVEBQCgoi6Xg2dfyh9ua4I87iSI/2le
-9IIAn1D4TKp1RgtXvSOY7KmvG7uC712d
-=iQUa
+iEYEAREIAAYFAk4+cK4ACgkQl5yvQNBFVTX4igCgl/SNhiv1n2mjqKucgwh8ruXE
+ci0An1nt+Zlg0BdBJ3YT9C5Lg3ExGHzm
+=28jq
-----END PGP SIGNATURE-----
diff --git a/sec-policy/selinux-skype/files/fix-apps-skype-r3.patch b/sec-policy/selinux-skype/files/fix-apps-skype-r3.patch
new file mode 100644
index 000000000000..337f39529b64
--- /dev/null
+++ b/sec-policy/selinux-skype/files/fix-apps-skype-r3.patch
@@ -0,0 +1,120 @@
+--- apps/skype.te 1970-01-01 01:00:00.000000000 +0100
++++ apps/skype.te 2011-07-24 17:24:40.996000734 +0200
+@@ -0,0 +1,111 @@
++policy_module(skype, 0.0.2)
++
++############################
++#
++# Declarations
++#
++
++type skype_t;
++type skype_exec_t;
++application_domain(skype_t, skype_exec_t)
++
++type skype_home_t;
++
++type skype_tmpfs_t;
++files_tmpfs_file(skype_tmpfs_t)
++ubac_constrained(skype_tmpfs_t)
++
++############################
++#
++# Policy
++#
++
++allow skype_t self:process { getsched setsched execmem signal };
++allow skype_t self:fifo_file rw_fifo_file_perms;
++allow skype_t self:unix_stream_socket create_socket_perms;
++allow skype_t self:sem create_sem_perms;
++allow skype_t self:tcp_socket create_stream_socket_perms;
++
++# Allow skype to work with its ~/.skype location
++manage_dirs_pattern(skype_t, skype_home_t, skype_home_t)
++manage_files_pattern(skype_t, skype_home_t, skype_home_t)
++manage_lnk_files_pattern(skype_t, skype_home_t, skype_home_t)
++
++# Needed for supporting X11 & shared memory
++manage_files_pattern(skype_t, skype_tmpfs_t, skype_tmpfs_t)
++manage_lnk_files_pattern(skype_t, skype_tmpfs_t, skype_tmpfs_t)
++manage_fifo_files_pattern(skype_t, skype_tmpfs_t, skype_tmpfs_t)
++manage_sock_files_pattern(skype_t, skype_tmpfs_t, skype_tmpfs_t)
++fs_tmpfs_filetrans(skype_t, skype_tmpfs_t, { file lnk_file sock_file fifo_file })
++
++# In Gentoo, the skype script calls skype binary. To keep the
++# number of privileges for the user domain sufficiently manageable,
++# we already label the script as skype_exec_t. Hence, the script
++# needs to be able to execute skype_exec_t files too.
++can_exec(skype_t, skype_exec_t)
++
++## Kernel layer calls
++#
++kernel_dontaudit_search_sysctl(skype_t)
++kernel_read_system_state(skype_t)
++
++corecmd_exec_bin(skype_t)
++corecmd_exec_shell(skype_t)
++
++corenet_all_recvfrom_netlabel(skype_t)
++corenet_all_recvfrom_unlabeled(skype_t)
++corenet_sendrecv_http_client_packets(skype_t)
++corenet_tcp_bind_generic_node(skype_t)
++corenet_tcp_bind_generic_port(skype_t)
++corenet_tcp_connect_generic_port(skype_t)
++corenet_tcp_connect_http_port(skype_t)
++corenet_tcp_sendrecv_http_port(skype_t)
++corenet_udp_bind_generic_node(skype_t)
++corenet_udp_bind_generic_port(skype_t)
++
++dev_read_sound(skype_t)
++dev_read_video_dev(skype_t)
++dev_write_sound(skype_t)
++dev_write_video_dev(skype_t)
++
++# Needed to debug skype (start through commandline)
++domain_use_interactive_fds(skype_t)
++
++files_read_etc_files(skype_t)
++files_read_usr_files(skype_t)
++
++## System layer calls
++#
++auth_use_nsswitch(skype_t)
++miscfiles_dontaudit_setattr_fonts_dirs(skype_t)
++miscfiles_read_localization(skype_t)
++userdom_manage_user_home_content_dirs(skype_t)
++userdom_manage_user_home_content_files(skype_t)
++userdom_use_user_terminals(skype_t)
++userdom_user_home_dir_filetrans(skype_t, skype_home_t, dir)
++userdom_user_home_content(skype_home_t)
++
++## Other calls
++#
++xserver_user_x_domain_template(skype, skype_t, skype_tmpfs_t)
++
++tunable_policy(`gentoo_try_dontaudit',`
++ dev_dontaudit_search_sysfs(skype_t)
++ fs_dontaudit_getattr_xattr_fs(skype_t)
++')
++
++optional_policy(`
++ tunable_policy(`gentoo_try_dontaudit',`
++ mozilla_dontaudit_manage_user_home_files(skype_t)
++ ')
++')
++
++optional_policy(`
++ alsa_read_rw_config(skype_t)
++')
++
++optional_policy(`
++ dbus_system_bus_client(skype_t)
++ dbus_session_bus_client(skype_t)
++')
++
+--- apps/skype.fc 1970-01-01 01:00:00.000000000 +0100
++++ apps/skype.fc 2011-07-21 10:08:43.824000256 +0200
+@@ -0,0 +1,3 @@
++/usr/bin/skype -- gen_context(system_u:object_r:skype_exec_t,s0)
++/opt/skype/skype -- gen_context(system_u:object_r:skype_exec_t,s0)
++HOME_DIR/\.Skype(/.*)? gen_context(system_u:object_r:skype_home_t,s0)
diff --git a/sec-policy/selinux-skype/selinux-skype-2.20101213-r3.ebuild b/sec-policy/selinux-skype/selinux-skype-2.20101213-r3.ebuild
new file mode 100644
index 000000000000..3ee903fb83e2
--- /dev/null
+++ b/sec-policy/selinux-skype/selinux-skype-2.20101213-r3.ebuild
@@ -0,0 +1,16 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sec-policy/selinux-skype/selinux-skype-2.20101213-r3.ebuild,v 1.1 2011/08/07 11:01:56 blueness Exp $
+
+IUSE=""
+
+MODS="skype"
+
+inherit selinux-policy-2
+
+DESCRIPTION="SELinux policy for general applications"
+
+KEYWORDS="~amd64 ~x86"
+
+POLICY_PATCH="${FILESDIR}/fix-apps-skype-r3.patch"
+RDEPEND=">=sec-policy/selinux-base-policy-2.20101213-r20"