Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp5717imm; Wed, 12 Sep 2018 16:55:37 -0700 (PDT) X-Google-Smtp-Source: ANB0Vdbv6L/FcY4KrtyK37vDPCAzLKZT2tGC1cDFnyqHpET663ZT1hG9JmvqSemr6EuZ9LP55ajg X-Received: by 2002:a17:902:a983:: with SMTP id bh3-v6mr4518539plb.245.1536796537074; Wed, 12 Sep 2018 16:55:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536796537; cv=none; d=google.com; s=arc-20160816; b=q2FbyTkSIo28/68zt+EctmPpsI+y/7EOQ2BXwSUqNjZM56cBEOBZr/AG0/FpIRZJu3 CZMADZl/XyhpcaFff1Lx0yj0/f6CtZYSXC4fx/DGkfdnyKNu6mlKUyoDcDGULPcffkBM r6sc3ThnH3XcKSTVGwS41HIGiMOrEaX+Z1Dj+gC51CEWE/seSfZ96fOjW37EejxgYYHH NjKfhH6LcdptTE3Vh8buSnSV7F8dFtIBM1KgGx7Wu4rjWuXu0Z4lRZgIgS+I6UCtTkZm 5TZSkqFL6b4TXT0MxJKIpyKlYgtPbEuAUhdNrwnOP8bBZSud8zUMD9VQ6G4H/dVMt2oB Ud4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature; bh=q0EQOHiyymoi/ChqeLMpmIWP8RLFQR5mfYVwn/b29KQ=; b=Nh0t+LvV5YoGuK4lRh/6XyMl17OZxxsa36/cwPj+UAUwwBQZccm21x17TRYwU5XNDr RpDDXhczeusGJLmDUJ66utXL0Fs3PZ7oByWIfKYTM6umnU0amtGTTDwNsrlv3QYQVOtT vA2zC9LYwt+kceuMm7uwt62DudkDH9Z51tPgF8v49TKFs4rCaraIniVAXkbPomxGiLp6 6HnaWm8byx6VSwr/1Hiwnd1gZ1rE4cut56LCKOBzd7RRBwW/wZ903AZ2QBh6clb+AFMW aYOOR9GyiRAJAejA0rp0ly2W5N783HfjhEn5V2JKGxuJAljJQ4z0dC8RdVFm09Rb3UYj RURw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=IrfivDUJ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 64-v6si2496172pfs.7.2018.09.12.16.55.22; Wed, 12 Sep 2018 16:55:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=IrfivDUJ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726912AbeIMFBc (ORCPT + 99 others); Thu, 13 Sep 2018 01:01:32 -0400 Received: from mail-yw1-f67.google.com ([209.85.161.67]:46563 "EHLO mail-yw1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726503AbeIMFBc (ORCPT ); Thu, 13 Sep 2018 01:01:32 -0400 Received: by mail-yw1-f67.google.com with SMTP id j131-v6so444744ywc.13 for ; Wed, 12 Sep 2018 16:54:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=q0EQOHiyymoi/ChqeLMpmIWP8RLFQR5mfYVwn/b29KQ=; b=IrfivDUJqwcPryKhGVxzKCfjX+jr2cY0Vubg/BVMQpT4dvdQd0lY3D7IRbaCPaBJyj Jn2GZ9YotKnCzgrJpQ49o6BDQ0+kYuji+vibz/hkFxSnAqejGkDyAT/SM5bk2V8lZYEB NbxVl2WFRzf76ZAYNJLXavZPww5j9mWhQOW/8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=q0EQOHiyymoi/ChqeLMpmIWP8RLFQR5mfYVwn/b29KQ=; b=JmUkd+xxV+PLTAWk8KcLhVoazNdXtylT6dV/Zqk+KhKmdOPCmvVLr0M5X+T2+m4jcR rrVgKeyQVVp0bSTfb1bvoajcs99lF4OpE4b5chm2Jm/qSmUqqt6S7AaX2e07zPyI2vku ERXme8L3cJj16xingDJ2qIlwycLAQWojMkiR2VLwmtLtDzWTSRmHZo3x0+VVe/+zXQaR TQPW6CgT/U+HtqW85Ac5fnmBShX/9v0GfuQAuiyskwXkUmtFtaMvrJkQTAs/cdPhxkHU kEF5Z5lHAujOk0RxGto5wS2li0e4it1tpO8fk5J1uQwPrIfJw+Ynmf4TbvIOU74Kw3zL PxAg== X-Gm-Message-State: APzg51AN902ehWKpvbxbrBwDAMfqvqJxtylWE1RxeAq2I7U9EiK24jlU b+eKljUSUxKTwNTDFSQ1vy4Hqj8lRGs= X-Received: by 2002:a81:2fc2:: with SMTP id v185-v6mr2159243ywv.199.1536796481383; Wed, 12 Sep 2018 16:54:41 -0700 (PDT) Received: from mail-yb1-f178.google.com (mail-yb1-f178.google.com. [209.85.219.178]) by smtp.gmail.com with ESMTPSA id i123-v6sm3237440ywe.14.2018.09.12.16.54.38 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 12 Sep 2018 16:54:39 -0700 (PDT) Received: by mail-yb1-f178.google.com with SMTP id j8-v6so2530359ybg.9 for ; Wed, 12 Sep 2018 16:54:38 -0700 (PDT) X-Received: by 2002:a25:5c87:: with SMTP id q129-v6mr2308185ybb.403.1536796478470; Wed, 12 Sep 2018 16:54:38 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a25:5f04:0:0:0:0:0 with HTTP; Wed, 12 Sep 2018 16:54:37 -0700 (PDT) In-Reply-To: <65bccad6-5669-9f4a-a645-35e0da301817@schaufler-ca.com> References: <65bccad6-5669-9f4a-a645-35e0da301817@schaufler-ca.com> From: Kees Cook Date: Wed, 12 Sep 2018 16:54:37 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 05/10] SELinux: Abstract use of file security blob To: Casey Schaufler Cc: LSM , James Morris , LKLM , SE Linux , John Johansen , Tetsuo Handa , Paul Moore , Stephen Smalley , "linux-fsdevel@vger.kernel.org" , Alexey Dobriyan , "Schaufler, Casey" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 11, 2018 at 9:41 AM, Casey Schaufler wrote: > Don't use the file->f_security pointer directly. > Provide a helper function that provides the security blob pointer. > > Signed-off-by: Casey Schaufler Seems delightfully mechanical. Reviewed-by: Kees Cook -Kees -- Kees Cook Pixel Security