From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 59C4E1381F3 for ; Mon, 30 Sep 2013 19:03:58 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id CAEFCE0BAA; Mon, 30 Sep 2013 19:03:44 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id F1CDCE0B7E for ; Mon, 30 Sep 2013 19:03:43 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 0B57533E24E for ; Mon, 30 Sep 2013 19:03:43 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 48314E5472 for ; Mon, 30 Sep 2013 19:03:41 +0000 (UTC) From: "Sven Vermeulen" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sven Vermeulen" Message-ID: <1380567786.9816ecb58b14813d55811e0fa9f54d50324216c3.swift@gentoo> Subject: [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/contrib/ X-VCS-Repository: proj/hardened-refpolicy X-VCS-Files: policy/modules/contrib/alsa.fc policy/modules/contrib/alsa.te X-VCS-Directories: policy/modules/contrib/ X-VCS-Committer: swift X-VCS-Committer-Name: Sven Vermeulen X-VCS-Revision: 9816ecb58b14813d55811e0fa9f54d50324216c3 X-VCS-Branch: master Date: Mon, 30 Sep 2013 19:03:41 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: ac1ea898-5cb2-4822-ae95-3c9d57803f30 X-Archives-Hash: 5baf50438dfe153da7deb7f7f9101e2b commit: 9816ecb58b14813d55811e0fa9f54d50324216c3 Author: Dominick Grift gmail com> AuthorDate: Fri Sep 27 16:28:52 2013 +0000 Commit: Sven Vermeulen gentoo org> CommitDate: Mon Sep 30 19:03:06 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-refpolicy.git;a=commit;h=9816ecb5 alsa: due to a bug in gnome 3.4, in debian, alsactl does all kinds of weird things related to pulseaudio Signed-off-by: Dominick Grift gmail.com> --- policy/modules/contrib/alsa.fc | 4 ++++ policy/modules/contrib/alsa.te | 25 +++++++++++++++++++------ 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/policy/modules/contrib/alsa.fc b/policy/modules/contrib/alsa.fc index 5de1e01..33d9d31 100644 --- a/policy/modules/contrib/alsa.fc +++ b/policy/modules/contrib/alsa.fc @@ -1,5 +1,9 @@ HOME_DIR/\.asoundrc -- gen_context(system_u:object_r:alsa_home_t,s0) +ifdef(`distro_debian',` +/\.config(/.*)? gen_context(system_u:object_r:alsa_var_lib_t,s0) +') + /bin/alsaunmute -- gen_context(system_u:object_r:alsa_exec_t,s0) /etc/alsa/asound\.state -- gen_context(system_u:object_r:alsa_etc_rw_t,s0) diff --git a/policy/modules/contrib/alsa.te b/policy/modules/contrib/alsa.te index 595a217..78d134a 100644 --- a/policy/modules/contrib/alsa.te +++ b/policy/modules/contrib/alsa.te @@ -20,8 +20,6 @@ files_tmp_file(alsa_tmp_t) type alsa_tmpfs_t; files_tmpfs_file(alsa_tmpfs_t) -pulseaudio_tmpfs_content(alsa_tmpfs_t) -dev_associate(alsa_tmpfs_t) type alsa_var_lib_t; files_type(alsa_var_lib_t) @@ -72,8 +70,6 @@ dev_write_sound(alsa_t) files_read_usr_files(alsa_t) files_search_var_lib(alsa_t) -fs_list_tmpfs(alsa_t) - term_dontaudit_use_console(alsa_t) term_dontaudit_use_generic_ptys(alsa_t) term_dontaudit_use_all_ptys(alsa_t) @@ -90,8 +86,25 @@ userdom_manage_unpriv_user_semaphores(alsa_t) userdom_manage_unpriv_user_shared_mem(alsa_t) userdom_search_user_home_dirs(alsa_t) -optional_policy(` - dbus_read_lib_files(alsa_t) +ifdef(`distro_debian',` + # Gnome 3.4 bug + dev_associate(alsa_tmpfs_t) + + allow alsa_t self:capability kill; + + manage_lnk_files_pattern(alsa_t, alsa_var_lib_t, alsa_var_lib_t) + files_root_filetrans(alsa_t, alsa_var_lib_t, dir, ".config") + + fs_getattr_tmpfs(alsa_t) + fs_list_tmpfs(alsa_t) + + optional_policy(` + dbus_read_lib_files(alsa_t) + ') + + optional_policy(` + pulseaudio_tmpfs_content(alsa_tmpfs_t) + ') ') optional_policy(`