加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
backport-Allow-confined-sysadmin-to-use-tool-vipw.patch 1.58 KB
一键复制 编辑 原始数据 按行查看 历史
lujie54 提交于 2022-09-13 20:45 . update upstream patches
From 9eec9eea6b6b74d8835928c32467f6edd749ff0e Mon Sep 17 00:00:00 2001
From: Patrik Koncity <pkoncity@redhat.com>
Date: Fri, 4 Feb 2022 12:04:16 +0100
Subject: [PATCH] Allow confined sysadmin to use tool vipw
Reference: https://gitbub.com/fedora-selinux/selinux-policy/commit/9eec9eea6b6b74d8835928c32467f6edd749ff0e
Conflict: NA
Allow confined sysadmin to use vipw and vigr, which edits passwd,
shadow, group, gshadow.. Dontaudit manage files and dir labeled
with admin_home_t. Also vipw need to use sss_cache tool.
Allow domain transition from sysadm_passwd_t to sssd_exec_t.
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2049018
Signed-off-by: lujie54 <lujie54@huawei.com>
---
policy/modules/admin/usermanage.te | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/policy/modules/admin/usermanage.te b/policy/modules/admin/usermanage.te
index a67fcc4..8fdbfbc 100644
--- a/policy/modules/admin/usermanage.te
+++ b/policy/modules/admin/usermanage.te
@@ -501,6 +501,8 @@ init_dontaudit_rw_utmp(sysadm_passwd_t)
logging_send_syslog_msg(sysadm_passwd_t)
userdom_use_unpriv_users_fds(sysadm_passwd_t)
+userdom_dontaudit_manage_admin_dir(sysadm_passwd_t)
+userdom_dontaudit_manage_admin_files(sysadm_passwd_t)
# user generally runs this from their home directory, so do not audit a search
# on user home dir
userdom_dontaudit_search_user_home_content(sysadm_passwd_t)
@@ -509,6 +511,10 @@ optional_policy(`
nscd_run(sysadm_passwd_t, sysadm_passwd_roles)
')
+optional_policy(`
+ sssd_domtrans(sysadm_passwd_t)
+')
+
########################################
#
# Useradd local policy
--
1.8.3.1
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化