From patchwork Thu Feb 16 14:51:58 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Smalley X-Patchwork-Id: 9577343 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 81D55600C5 for ; Thu, 16 Feb 2017 14:49:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6C19A285FD for ; Thu, 16 Feb 2017 14:49:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5E28D285FF; Thu, 16 Feb 2017 14:49:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from emsm-gh1-uea11.nsa.gov (smtp.nsa.gov [8.44.101.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 20658285FD for ; Thu, 16 Feb 2017 14:49:48 +0000 (UTC) X-IronPort-AV: E=Sophos;i="5.35,169,1484006400"; d="scan'208";a="3231054" IronPort-PHdr: =?us-ascii?q?9a23=3A27iZyxG/9vEVsOxpWH/D8J1GYnF86YWxBRYc798d?= =?us-ascii?q?s5kLTJ79pcm4bnLW6fgltlLVR4KTs6sC0LuL9fi8EjJdqb+681k6OKRWUBEEjc?= =?us-ascii?q?hE1ycBO+WiTXPBEfjxciYhF95DXlI2t1uyMExSBdqsLwaK+i764jEdAAjwOhRo?= =?us-ascii?q?LerpBIHSk9631+ev8JHPfglEnjSwbLdyIRmssQncucYajIpiJ60s1hbHv3xEdv?= =?us-ascii?q?hMy2h1P1yThRH85smx/J5n7Stdvu8q+tBDX6vnYak2VKRUAzs6PW874s3rrgTD?= =?us-ascii?q?QhCU5nQASGUWkwFHDBbD4RrnQ5r+qCr6tu562CmHIc37SK0/VDq+46t3ThLjlS?= =?us-ascii?q?kINyQ98GrKlMJ+iqxVqw+lqxBm3YLYfISZOfxjda3fYNwaX3JMUMZPWSJcDI2y?= =?us-ascii?q?bIwBD/IDMOpFoYTyqEcBoxSgCgm3H+7v1j1Fi2Xq0aAgz+gtDwfL1xEgEdIUt3?= =?us-ascii?q?TUqc34OroOUe+r1KnIzSvMb/VL0jng7YjHaBQhofWSUrNwbMHczlIvGB7ejliL?= =?us-ascii?q?tYzkPy+a1uQKs2SB6epgTvigh3QoqwF2vDii38EhgZTKiIIN0l3I6Cp0zYkvKd?= =?us-ascii?q?C4VUJ3e8CoHZROuy2AKod7RN4pTXtytyYg0LIGvIa2fC0NyJs62RHSc+eHc42U?= =?us-ascii?q?4hL7U+aRPCt4iGpleL2hgxay9lCtyvHmWcmu0VZKszFFnsPQtnENyxPT6s+HRu?= =?us-ascii?q?F7/ki9wjaAyxrf6uRFIUAwjabbKpghzaAslpcLrEjOESD7lF/2gaOLbEko5Oel?= =?us-ascii?q?5/r9brn7vpOcMpV7igD6MqQggMy/BuE4PxAVX2eF/eS81bvj/VD2QblTlfI2lb?= =?us-ascii?q?TZsJbGKssFva60GBNV04Y/5Ba/CDeqytIYnWIdI15fdxKHiJbpN0nUIP/kFfe/?= =?us-ascii?q?n0iskDBzyvDEOb3hBI/CLmTDkLj7e7Zw8ExcyA01zdBa/Z1UEa0BL+zpWk/qrt?= =?us-ascii?q?DYCQU5MwOsyeb9FNp9zp8eWX6IAqKBMqPSs0WH6f4sI+mXY48Vvjf9K+Y+6v7g?= =?us-ascii?q?iX85hFAccrK03ZsRdHC4A+5qI0KDYXrjmt0BC3sFvhIiTOz2j12PSTBSZ3e2X6?= =?us-ascii?q?I5+D47EpmrDYndSY+wh7yBxj20HoVMZmBBCFCDD2vnd5meV/cLciKSLddrkiYY?= =?us-ascii?q?Wri5V48hyRauuRfnxLV7K+rU/SsYtY7+2NVu+e3ciwsy9T11DsSa1WGBVWd0kX?= =?us-ascii?q?0URzUuxqBwvVR9ykuf0ah/m/FXCMBT6OlTUgohKZHcyOl6BMzoVQLaYteFUlCm?= =?us-ascii?q?Tcu6ATspVNI+38cOY1phG9Wllh3C3yurA7gTl7GQAZw09rvQ33n3J8pnzXbJzr?= =?us-ascii?q?Mhj1onQstRK2KqnKh/+BbPB4TRiUWWi76qdbgA3C7K7GqM03KOs1tCUA5xSqXI?= =?us-ascii?q?RmgfaVHMrdT4/UPCV7uuBq47PQRf08KCLbFKatLxh1VcWPjjIMjeY362m2qoCx?= =?us-ascii?q?aI3KmDbIz2dGUcxyXQE00EkxgS/XqfLgg/CDyhr3jZDDx0GlLle1ns/vVmqHOn?= =?us-ascii?q?Uk80yBmHb0572Lq2/R4VmOeRS/AJ0bIHvychti94HFGn39LZE9CAvRZufL1AYd?= =?us-ascii?q?Mh51dKzXjWuBFnPpyhMa9inEUTfB5rsEPrzRl3DZ9AkccypnMw0AVyMb6Y0E9G?= =?us-ascii?q?dz6A3ZD/JLnXKm31/B20b67Wx03e0NGT+qgV8vg4rE/jvA6xHEo473pny8VV02?= =?us-ascii?q?eb5pjSFwoSX4jxUkEs9xhmvLzaeS8954Ta1H1pK6a0tCXO29Q3C+s50hygZctQ?= =?us-ascii?q?MLuYFA/uFM0XH8avJ/Yum1i1cB0EJvtS+bUqP8y4bfuJw7OrPON6kDKhl2RH75?= =?us-ascii?q?h30liQ+CpkVu7Iw5EFzumE3gSaSjj8jU2ussTslI9YYjESG3awxjL/BI5NfKFy?= =?us-ascii?q?e5gECXu2Kc2t2tp+n4LtW2Jf9FO7AVMG2cupeR6MYFzmxgBfz1oYoWagmSeiyD?= =?us-ascii?q?x0iT4ppLKF3CPS2+TiaAYHOmlTSWl8jFfjPZS0j9cAXESycwcplByl5UD1x6VA?= =?us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4TlmOhXOMJYEpxDDwu4U/ZqjH1NNgBv93DAnRT/aYWSJYMafwv5JTTNY?= =?us-ascii?q?MOz/szmjFruio3t2OaFVwOoBiC9v/rAK9kxrBErVI99vVyU1DHFyjTaUDb24Gm?= =?us-ascii?q?DIRJ3i4ornf6gZmH9ttxPadX8tkqSGwBBjh7c5WHpT0=3D?= X-IPAS-Result: =?us-ascii?q?A2G2AwDVuqVY/wHyM5BeGgEBAQECAQEBAQgBAQEBFQEBAQE?= =?us-ascii?q?CAQEBAQgBAQEBgyaBao5Tj3ABAQEBAQEGmF0jiAxXAQEBAQEBAQECAQJfKIIzI?= =?us-ascii?q?oIjAiQTFCALAwMJAhcpCAgDAS0VHwsFGASJPg2yLjomAosfJoYHiVoLBgGCaAy?= =?us-ascii?q?DDQWJDoc2izuKEYgGAoF5iFsMhiICkxhYeAgZBwISCBsPPYRGHYF/V4d7DheCF?= =?us-ascii?q?wEBAQ?= Received: from unknown (HELO tarius.tycho.ncsc.mil) ([144.51.242.1]) by emsm-gh1-uea11.nsa.gov with ESMTP; 16 Feb 2017 14:49:43 +0000 Received: from prometheus.infosec.tycho.ncsc.mil (prometheus [192.168.25.40]) by tarius.tycho.ncsc.mil (8.14.4/8.14.4) with ESMTP id v1GEmjJp030158; Thu, 16 Feb 2017 09:49:01 -0500 Received: from tarius.tycho.ncsc.mil (tarius.infosec.tycho.ncsc.mil [144.51.242.1]) by prometheus.infosec.tycho.ncsc.mil (8.15.2/8.15.2) with ESMTP id v1GEmgiw096337 for ; Thu, 16 Feb 2017 09:48:42 -0500 Received: from moss-pluto.infosec.tycho.ncsc.mil (moss-pluto [192.168.25.131]) by tarius.tycho.ncsc.mil (8.14.4/8.14.4) with ESMTP id v1GEmdGT030151; Thu, 16 Feb 2017 09:48:39 -0500 From: Stephen Smalley To: linux-security-module@vger.kernel.org Subject: [PATCH] prlimit,security,selinux: add a security hook for prlimit Date: Thu, 16 Feb 2017 09:51:58 -0500 Message-Id: <1487256718-26141-1-git-send-email-sds@tycho.nsa.gov> X-Mailer: git-send-email 2.7.4 X-BeenThere: selinux@tycho.nsa.gov X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Security-Enhanced Linux \(SELinux\) mailing list" List-Post: List-Help: Cc: Stephen Smalley , jslaby@suse.cz, james.l.morris@oracle.com, selinux@tycho.nsa.gov MIME-Version: 1.0 Errors-To: selinux-bounces@tycho.nsa.gov Sender: "Selinux" X-Virus-Scanned: ClamAV using ClamSMTP When SELinux was first added to the kernel, a process could only get and set its own resource limits via getrlimit(2) and setrlimit(2), so no MAC checks were required for those operations, and thus no security hooks were defined for them. Later, SELinux introduced a hook for setlimit(2) with a check if the hard limit was being changed in order to be able to rely on the hard limit value as a safe reset point upon context transitions. Later on, when prlimit(2) was added to the kernel with the ability to get or set resource limits (hard or soft) of another process, LSM/SELinux was not updated other than to pass the target process to the setrlimit hook. This resulted in incomplete control over both getting and setting the resource limits of another process. Add a new security_task_prlimit() hook to the check_prlimit_permission() function to provide complete mediation. The hook is only called when acting on another task, and only if the existing DAC/capability checks would allow access. Pass flags down to the hook to indicate whether the prlimit(2) call will read, write, or both read and write the resource limits of the target process. The existing security_task_setrlimit() hook is left alone; it continues to serve a purpose in supporting the ability to make decisions based on the old and/or new resource limit values when setting limits. This is consistent with the DAC/capability logic, where check_prlimit_permission() performs generic DAC/capability checks for acting on another task, while do_prlimit() performs a capability check based on a comparison of the old and new resource limits. Fix the inline documentation for the hook to match the code. Implement the new hook for SELinux. For setting resource limits, we reuse the existing setrlimit permission. Note that this does overload the setrlimit permission to mean the ability to set the resource limit (soft or hard) of another process or the ability to change one's own hard limit. For getting resource limits, a new getrlimit permission is defined. This was not originally defined since getrlimit(2) could only be used to obtain a process' own limits. Signed-off-by: Stephen Smalley --- include/linux/lsm_hooks.h | 18 +++++++++++++++--- include/linux/security.h | 6 ++++++ kernel/sys.c | 30 ++++++++++++++++++------------ security/security.c | 8 ++++++++ security/selinux/hooks.c | 14 ++++++++++++++ security/selinux/include/classmap.h | 2 +- 6 files changed, 62 insertions(+), 16 deletions(-) diff --git a/include/linux/lsm_hooks.h b/include/linux/lsm_hooks.h index 6fe7a5c..5832f74 100644 --- a/include/linux/lsm_hooks.h +++ b/include/linux/lsm_hooks.h @@ -631,10 +631,19 @@ * Check permission before getting the ioprio value of @p. * @p contains the task_struct of process. * Return 0 if permission is granted. + * @task_prlimit: + * Check permission before getting and/or setting the resource limits of + * another task. + * @cred points to the cred structure for the current task. + * @tcred points to the cred structure for the target task. + * @flags contains the LSM_PRLIMIT_* flag bits indicating whether the + * resource limits are being read, modified, or both. + * Return 0 if permission is granted. * @task_setrlimit: - * Check permission before setting the resource limits of the current - * process for @resource to @new_rlim. The old resource limit values can - * be examined by dereferencing (current->signal->rlim + resource). + * Check permission before setting the resource limits of process @p + * for @resource to @new_rlim. The old resource limit values can + * be examined by dereferencing (p->signal->rlim + resource). + * @p points to the task_struct for the target task's group leader. * @resource contains the resource whose limit is being set. * @new_rlim contains the new limits for @resource. * Return 0 if permission is granted. @@ -1495,6 +1504,8 @@ union security_list_options { int (*task_setnice)(struct task_struct *p, int nice); int (*task_setioprio)(struct task_struct *p, int ioprio); int (*task_getioprio)(struct task_struct *p); + int (*task_prlimit)(const struct cred *cred, const struct cred *tcred, + unsigned int flags); int (*task_setrlimit)(struct task_struct *p, unsigned int resource, struct rlimit *new_rlim); int (*task_setscheduler)(struct task_struct *p); @@ -1756,6 +1767,7 @@ struct security_hook_heads { struct list_head task_setnice; struct list_head task_setioprio; struct list_head task_getioprio; + struct list_head task_prlimit; struct list_head task_setrlimit; struct list_head task_setscheduler; struct list_head task_getscheduler; diff --git a/include/linux/security.h b/include/linux/security.h index d3868f2..cce29ba 100644 --- a/include/linux/security.h +++ b/include/linux/security.h @@ -133,6 +133,10 @@ extern unsigned long dac_mmap_min_addr; /* setfsuid or setfsgid, id0 == fsuid or fsgid */ #define LSM_SETID_FS 8 +/* Flags for security_task_prlimit(). */ +#define LSM_PRLIMIT_READ 1 +#define LSM_PRLIMIT_WRITE 2 + /* forward declares to avoid warnings */ struct sched_param; struct request_sock; @@ -325,6 +329,8 @@ void security_task_getsecid(struct task_struct *p, u32 *secid); int security_task_setnice(struct task_struct *p, int nice); int security_task_setioprio(struct task_struct *p, int ioprio); int security_task_getioprio(struct task_struct *p); +int security_task_prlimit(const struct cred *cred, const struct cred *tcred, + unsigned int flags); int security_task_setrlimit(struct task_struct *p, unsigned int resource, struct rlimit *new_rlim); int security_task_setscheduler(struct task_struct *p); diff --git a/kernel/sys.c b/kernel/sys.c index 842914e..8a364f7 100644 --- a/kernel/sys.c +++ b/kernel/sys.c @@ -1425,25 +1425,26 @@ int do_prlimit(struct task_struct *tsk, unsigned int resource, } /* rcu lock must be held */ -static int check_prlimit_permission(struct task_struct *task) +static int check_prlimit_permission(struct task_struct *task, + unsigned int flags) { const struct cred *cred = current_cred(), *tcred; + bool id_match; if (current == task) return 0; tcred = __task_cred(task); - if (uid_eq(cred->uid, tcred->euid) && - uid_eq(cred->uid, tcred->suid) && - uid_eq(cred->uid, tcred->uid) && - gid_eq(cred->gid, tcred->egid) && - gid_eq(cred->gid, tcred->sgid) && - gid_eq(cred->gid, tcred->gid)) - return 0; - if (ns_capable(tcred->user_ns, CAP_SYS_RESOURCE)) - return 0; + id_match = (uid_eq(cred->uid, tcred->euid) && + uid_eq(cred->uid, tcred->suid) && + uid_eq(cred->uid, tcred->uid) && + gid_eq(cred->gid, tcred->egid) && + gid_eq(cred->gid, tcred->sgid) && + gid_eq(cred->gid, tcred->gid)); + if (!id_match && !ns_capable(tcred->user_ns, CAP_SYS_RESOURCE)) + return -EPERM; - return -EPERM; + return security_task_prlimit(cred, tcred, flags); } SYSCALL_DEFINE4(prlimit64, pid_t, pid, unsigned int, resource, @@ -1453,12 +1454,17 @@ SYSCALL_DEFINE4(prlimit64, pid_t, pid, unsigned int, resource, struct rlimit64 old64, new64; struct rlimit old, new; struct task_struct *tsk; + unsigned int checkflags = 0; int ret; + if (old_rlim) + checkflags |= LSM_PRLIMIT_READ; + if (new_rlim) { if (copy_from_user(&new64, new_rlim, sizeof(new64))) return -EFAULT; rlim64_to_rlim(&new64, &new); + checkflags |= LSM_PRLIMIT_WRITE; } rcu_read_lock(); @@ -1467,7 +1473,7 @@ SYSCALL_DEFINE4(prlimit64, pid_t, pid, unsigned int, resource, rcu_read_unlock(); return -ESRCH; } - ret = check_prlimit_permission(tsk); + ret = check_prlimit_permission(tsk, checkflags); if (ret) { rcu_read_unlock(); return ret; diff --git a/security/security.c b/security/security.c index 8c9fee5..8178c84 100644 --- a/security/security.c +++ b/security/security.c @@ -998,6 +998,12 @@ int security_task_getioprio(struct task_struct *p) return call_int_hook(task_getioprio, 0, p); } +int security_task_prlimit(const struct cred *cred, const struct cred *tcred, + unsigned int flags) +{ + return call_int_hook(task_prlimit, 0, cred, tcred, flags); +} + int security_task_setrlimit(struct task_struct *p, unsigned int resource, struct rlimit *new_rlim) { @@ -1755,6 +1761,8 @@ struct security_hook_heads security_hook_heads = { LIST_HEAD_INIT(security_hook_heads.task_setioprio), .task_getioprio = LIST_HEAD_INIT(security_hook_heads.task_getioprio), + .task_prlimit = + LIST_HEAD_INIT(security_hook_heads.task_prlimit), .task_setrlimit = LIST_HEAD_INIT(security_hook_heads.task_setrlimit), .task_setscheduler = diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 76af95f..be5cc90 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c @@ -3917,6 +3917,19 @@ static int selinux_task_getioprio(struct task_struct *p) PROCESS__GETSCHED, NULL); } +int selinux_task_prlimit(const struct cred *cred, const struct cred *tcred, + unsigned int flags) +{ + u32 av = 0; + + if (flags & LSM_PRLIMIT_WRITE) + av |= PROCESS__SETRLIMIT; + if (flags & LSM_PRLIMIT_READ) + av |= PROCESS__GETRLIMIT; + return avc_has_perm(cred_sid(cred), cred_sid(tcred), + SECCLASS_PROCESS, av, NULL); +} + static int selinux_task_setrlimit(struct task_struct *p, unsigned int resource, struct rlimit *new_rlim) { @@ -6202,6 +6215,7 @@ static struct security_hook_list selinux_hooks[] = { LSM_HOOK_INIT(task_setnice, selinux_task_setnice), LSM_HOOK_INIT(task_setioprio, selinux_task_setioprio), LSM_HOOK_INIT(task_getioprio, selinux_task_getioprio), + LSM_HOOK_INIT(task_prlimit, selinux_task_prlimit), LSM_HOOK_INIT(task_setrlimit, selinux_task_setrlimit), LSM_HOOK_INIT(task_setscheduler, selinux_task_setscheduler), LSM_HOOK_INIT(task_getscheduler, selinux_task_getscheduler), diff --git a/security/selinux/include/classmap.h b/security/selinux/include/classmap.h index 7898ffa..da0e74c 100644 --- a/security/selinux/include/classmap.h +++ b/security/selinux/include/classmap.h @@ -47,7 +47,7 @@ struct security_class_mapping secclass_map[] = { "getattr", "setexec", "setfscreate", "noatsecure", "siginh", "setrlimit", "rlimitinh", "dyntransition", "setcurrent", "execmem", "execstack", "execheap", "setkeycreate", - "setsockcreate", NULL } }, + "setsockcreate", "getrlimit", NULL } }, { "system", { "ipc_info", "syslog_read", "syslog_mod", "syslog_console", "module_request", "module_load", NULL } },