Message ID | 20220927195421.14713-32-casey@schaufler-ca.com (mailing list archive) |
---|---|
State | Changes Requested |
Delegated to: | Paul Moore |
Headers | show
Return-Path: <linux-security-module-owner@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EB081C6FA83 for <linux-security-module@archiver.kernel.org>; Tue, 27 Sep 2022 20:11:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232927AbiI0ULz (ORCPT <rfc822;linux-security-module@archiver.kernel.org>); Tue, 27 Sep 2022 16:11:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59494 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232931AbiI0ULe (ORCPT <rfc822;linux-security-module@vger.kernel.org>); Tue, 27 Sep 2022 16:11:34 -0400 Received: from sonic308-15.consmr.mail.ne1.yahoo.com (sonic308-15.consmr.mail.ne1.yahoo.com [66.163.187.38]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AA2CD130BC7 for <linux-security-module@vger.kernel.org>; Tue, 27 Sep 2022 13:10:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1664309450; bh=rYxxCr1vY4SS1ZjcTEiLgKsS7D/yNtgX53qXB2wQNf4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From:Subject:Reply-To; b=r6NEBmSelYdXqWHpNna0y3jPLZUR474cRsEx92IGBZ99KcwkeEymTRq6r2RVzxdENRSWEfm95VZ2HozTA0NYPBnZe6upWD9xJPjjVofE+aC+D0zenzs03XqM2XrAFUTK0wdAjrS+BvpuRwBPJwP9GIS4a2bPcHjZmz6iIBPQ1N9Tam5yJfsM4pmY2MqDJieoSSbQcj+fHDbgAap/tVTDfqtNDuK3GHk3/goWnHfXU1b5hVTQbN3dTOlEL/g500TqJZv1dNSxG83pae84LwSSXglDJ9fQgFi6rTWglHszvN8BeI+VcQEiFndT7yMmU/BS/9KdhfPzMFeu6KY+Rfbygg== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1664309450; bh=Pm78uT9GOCBV/z8p/R0bTSuyKxTpmx6NZc1YqKL+qrm=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=FlX25q0yk+u5QLzXqlpB5jE9/pFfL/8XM/+rCZzsz2GBdD2KfYUwm0g2crqv4F8my2dqI4AHasU6+WUClxyFw894Jpevqn5JZx+L/6kP9Vuq4tIXIFTp99UJ+HNvF+YeYeXRWxTUKD403K2K5UCz0WUCHmqzb5awJ3cpP1q04V9CIHN2usuRK6XWbdjA7uL8i+QElZXPHaWq9EwGjgf4MjQWbqlDY9/y/cgsuszuyne2pqX0okb7EXRWmes/kUY1BfvDk2DH19XKSyc+XqYO6fPZNRHzqKjnQMgtO+BMGZycE/exnEvPnimSIYvMO+J2R0A1rkJTJrtzjy4iu2SqFQ== X-YMail-OSG: H8mhBNUVM1lTvWe4r3SvyNsoU1BebnK8RaDhI96IPcxJQuWqz37MOitw0oxocmP e6hbrbAC_jZna61CsFeOavOPI5.Nd1pV.v9zKyUW6QKZhfOF6HHxxO0Ckq7CE7MYyHKmkjC0Hsw2 YQZtJhvsaVtfysq7rNJKuVHqmwfgC.RiLvpuFXxSyvkAFxg5KY.uKcmpe8bQAGyDdTZGH_1aeo3g .F.AXojkw5quiihBdEdLck9yvowXgBQceh3sKlsDvp8r8ZgmzwId_nWixfF9b0icLqRYPc6md_xn VNieAYfyo.OWHsF5NnSelDXJR84dE_zRRukfm0J2R5bEucugy5gufmCQiwXxdKFIvjFXvpg4bQLq 1zdRQXK78uLYOP78hQPrwbXd3S0uJ5uE9D7EVUJQOBkLazkpTC5JscfJAN6vcWeUl487Fzk0eXeZ b46.FTm1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mYoyZqI69VqI2qYod4gR2llhbl3AygwCs9a85Iq9kyV4ZX4yYO5 HzjcvwNumXHF93v9nMndax00azk3bbsfTAmdbMI6p6NsGccERS76W256VIWBOT85EeMGioDBMApP saA98ScQMcVk3zUtrPApQKgrFcj6sL0JUSdXhtyCJ3YoIFcVyT6.mMVOv3_gGhNBAXTh95od.isw Me9Gyan_OX6ZKWXtnSxfzHSxoLIMLBj4edIuouYd4Cs7yLrA84GivYksKA6UvWXTTYmqSWhgun8d jSPUhY488l.hwDiBpQNHy0emgQiBzCR1iNlrRjBevbqxA_ERRZ66Vc6qLgqvjC_nzSKwO_6SBHN9 ocvBSPkorV4jiX2GyyjEkzSDO1Is8LSDtoaeY2625JkxlR9IOdacEa17ydt7Ky2EJihu._3auH.d iVDZ9CFTmF4wpjsLgWPb_W2C.7zwBKqTXPcpAU4Cf_Ti8fbS5EZ4qyNLw5YheJh7iq_ixJPcCcim CnY0hJpCh5UmEDvINyIbro5LiQM7XSk2c06f7GwaVpSjBVst_W.to1eE7JgLhd7GrBxfYecJ49Ic dGkLsEWz8krDlaFBqdLJcxZQ4StyRjUBpb7Vvww1IqpOJIKbBEfbP8A3lbUurBdsPwSo1EKaw8ki sTteO1guSVv_rBJv56Hz47Kw61OK3PhXytihZv6K9ac4v9Qa9kZq16Hozfxu2BsEZ02MBZtY0Ewm 32fZC.COspaDjBBYWVWvw_pTXLT6jcL._n5N1V4QsCUMibAwYYZaJTCE1X0lHOc7.3iGlywbPzxx 5tEEvm5T.uc5wwCk57LRhmrsqSXU9m2mdFbPOZ.M- X-Sonic-MF: <casey@schaufler-ca.com> Received: from sonic.gate.mail.ne1.yahoo.com by sonic308.consmr.mail.ne1.yahoo.com with HTTP; Tue, 27 Sep 2022 20:10:50 +0000 Received: by hermes--production-gq1-7dfd88c84d-nvfk6 (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 55a7229bea084bb6b28fa3beefd2f4cd; Tue, 27 Sep 2022 20:10:47 +0000 (UTC) From: Casey Schaufler <casey@schaufler-ca.com> To: casey.schaufler@intel.com, paul@paul-moore.com, linux-security-module@vger.kernel.org Cc: casey@schaufler-ca.com, linux-audit@redhat.com, jmorris@namei.org, selinux@vger.kernel.org, keescook@chromium.org, john.johansen@canonical.com, penguin-kernel@i-love.sakura.ne.jp, stephen.smalley.work@gmail.com, linux-kernel@vger.kernel.org Subject: [PATCH v38 31/39] LSM: Add a function to report multiple LSMs Date: Tue, 27 Sep 2022 12:54:13 -0700 Message-Id: <20220927195421.14713-32-casey@schaufler-ca.com> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20220927195421.14713-1-casey@schaufler-ca.com> References: <20220927195421.14713-1-casey@schaufler-ca.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: <linux-security-module.vger.kernel.org> |
Series |
LSM: Module stacking for AppArmor
|
expand
|
diff --git a/include/linux/security.h b/include/linux/security.h index 170b303e9122..c190b9189287 100644 --- a/include/linux/security.h +++ b/include/linux/security.h @@ -262,6 +262,15 @@ static inline const char *lsm_slot_to_name(int slot) } #endif +static inline bool lsm_multiple_contexts(void) +{ +#ifdef CONFIG_SECURITY + return lsm_slot_to_name(1) != NULL; +#else + return false; +#endif +} + /** * lsmblob_value - find the first non-zero value in an lsmblob structure. * @blob: Pointer to the data