Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp564606pxk; Thu, 24 Sep 2020 12:21:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz1gQP7p/ndykHUwLA82fuDBwZci8RL0frJtXHipR7PDWvrJLc3PQNqVIGu1YUFWrnC+xZb X-Received: by 2002:a17:906:4902:: with SMTP id b2mr175950ejq.208.1600975265505; Thu, 24 Sep 2020 12:21:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600975265; cv=none; d=google.com; s=arc-20160816; b=yyKW8nfCfJ6ZbPQ/jY4zY+YdEVN+wz//+TcQP2+y/CXqWs84WxPHdetKM9YOJUWdAs gQTjVT60OjbhD3qzUtTx8iHRBLMfXGtlmzMGZKPOCoE1iJzmAMFpOE2ao9pdHiYVtRnB ks4OR9eBkyWqpK+Odg8eNWweZS77cSI9TIxUpCiu2ri+io6VORMlj0HENCbzasQRMBtW NciSIgw8NOmX4BMpHn5pXSIucPGcLimdy7WA4GPm0S4L0PrggV/kXXUa24JXEHaeQbwF 8Hfm8M4YeDEJ/L2L7+4qUe9JliallW2i0+B29hwsLdJR555vyF7VT1cxhSaECAQ3xCfq ogsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=rL+0r4nsYsaTnfsp4nKpvqpdZr9u7FgIPOgyMKNt8zc=; b=TLR0qxCASLer1pzKz5ShlrvkPnau0DvgL99054sahiYDgvhHqHCP3iQxS8FnIlRFKh brYUx49MF835jjiCG/P6bWIHwN99UZGy0p3ujXSGV8ZBpMl0dFeeZj2NfnkISmhasItP 6xvfj9OcZIZSrSgHvLsMAcibGA3Xf5FXreDhAnTacJttuJhjvpLRP5f9+zfn1z9MOnKF Ue+uYGD+xPkM8RpOB295bdWccnijUzmbQaI3ZW8z6Pjpv/wjZ5B0ma3uFzUiDQWJ1PMU 6UKtmQcfL92IarpWZodGWReWM3eA75pJjZlvvP5TJ5MOG+jNRws7smszfnAeOPpSsn0g YApw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=nW6H9Ez9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o9si277666ejx.707.2020.09.24.12.20.41; Thu, 24 Sep 2020 12:21:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=nW6H9Ez9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728772AbgIXTTB (ORCPT + 99 others); Thu, 24 Sep 2020 15:19:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46190 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727992AbgIXTTB (ORCPT ); Thu, 24 Sep 2020 15:19:01 -0400 Received: from mail-ej1-x644.google.com (mail-ej1-x644.google.com [IPv6:2a00:1450:4864:20::644]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CD053C0613D4 for ; Thu, 24 Sep 2020 12:19:00 -0700 (PDT) Received: by mail-ej1-x644.google.com with SMTP id r7so272636ejs.11 for ; Thu, 24 Sep 2020 12:19:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=rL+0r4nsYsaTnfsp4nKpvqpdZr9u7FgIPOgyMKNt8zc=; b=nW6H9Ez9qPwsgMVuKmXTOIP47WKziOB7h4ORZWYHlPlZmcmBaz4bHW4IU2YbZsB5hb PKuFmofW4Zkf/3SgserbbqW7aN+s9iDgZbxr9QF0a+XDOyQauEYVVSL/KnakazhwL9D4 UwrK4zx1t+sRU7ddaxgI/KYI1iAsm8WFKpkl5/8qG0kYIZDGGh7V/oUZv2AqOwFcMrap DSM8JWFJFnMD99cr4rEr96PRqnbogR9L4C448SM/gzvmeyrVEi1RWLhCxTScPIvkxccL bhyh0HeLsDXVkXxuvggdeni2CgIY8uiKUYP88tL+eo2IucDIcb5mZtmgFAHFmYwp06Dk cHcw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=rL+0r4nsYsaTnfsp4nKpvqpdZr9u7FgIPOgyMKNt8zc=; b=jKWiB4uUMa1388MepH3HMLzBBAYWicsB1+pmOsjROBu1guoUllUV20Y5TF2eMxmNd/ FCDoRz7ydEkQJtEZyzsL4ACvAMPGKe0RgERYTV/ZFEC8zTQOmNMcA6BfJb/1IFX49Izf FxiVQnM8NxeYM8m/NIr0K0LFE8qanJzIVjd04ggAywSjLlSDFT79bB0pLVPqKiYBgPSv CCtRGlQoNoRnb6Ai7qyH+dWbBl9wrKdpJvYxkWjQuXcHl8d4ZJNWfgOvqxOQMcMxa0nv ZuJ1/rpUb+RAODQHvYTG1zCaWa8qZc08hsSHQ7wmHDo5LyDrNJoyNt5Q3LV1Z++RYRQI YJAg== X-Gm-Message-State: AOAM533aAsLe3mVWF6STmc62cQLVKUawevWAo8qvlExZl+2nPl9rZxaY OhWlGbgnj89wvs1C91KJbxlT11FpapO1D6csSXaWOQ== X-Received: by 2002:a17:907:94cf:: with SMTP id dn15mr176599ejc.114.1600975139153; Thu, 24 Sep 2020 12:18:59 -0700 (PDT) MIME-Version: 1.0 References: <20200923232923.3142503-1-keescook@chromium.org> <20200924185702.GA9225@redhat.com> In-Reply-To: <20200924185702.GA9225@redhat.com> From: Jann Horn Date: Thu, 24 Sep 2020 21:18:32 +0200 Message-ID: Subject: Re: [PATCH v1 0/6] seccomp: Implement constant action bitmaps To: Andrea Arcangeli Cc: Kees Cook , YiFei Zhu , Christian Brauner , Tycho Andersen , Andy Lutomirski , Will Drewry , Giuseppe Scrivano , Tobin Feldman-Fitzthum , Dimitrios Skarlatos , Valentin Rothberg , Hubertus Franke , Jack Chen , Josep Torrellas , Tianyin Xu , bpf , Linux Containers , Linux API , kernel list Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 24, 2020 at 8:57 PM Andrea Arcangeli wrote: > > Hello, > > I'm posting this only for the record, feel free to ignore. > > On Wed, Sep 23, 2020 at 04:29:17PM -0700, Kees Cook wrote: > > rfc: https://lore.kernel.org/lkml/20200616074934.1600036-1-keescook@chromium.org/ > > alternative: https://lore.kernel.org/containers/cover.1600661418.git.yifeifz2@illinois.edu/ > > v1: > > - rebase to for-next/seccomp > > - finish X86_X32 support for both pinning and bitmaps > > It's pretty clear the O(1) seccomp filter bitmap was first was > proposed by your RFC in June (albeit it was located in the wrong place > and is still in the wrong place in v1). > > > - replace TLB magic with Jann's emulator > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > > That's a pretty fundamental change in v1 compared to your the > non-competing TLB magic technique you used in the RFC last June. > > The bitmap isn't the clever part of the patch, the bitmap can be > reviewed in seconds, the difficult part to implement and to review is > how you fill the bitmap and in that respect there's absolutely nothing > in common in between the "rfc:" and the "alternative" link. > > In June your bitmap-filling engine was this: > > https://lore.kernel.org/lkml/20200616074934.1600036-5-keescook@chromium.org/ > > Then on Sep 21 YiFei Zhu posted his new innovative BPF emulation > innovation that obsoleted your TLB magic of June: > > https://lists.linuxfoundation.org/pipermail/containers/2020-September/042153.html > > And on Sep 23 instead of collaborating and helping YiFei Zhu to > improve his BPF emulator, you posted the same technique that looks > remarkably similar without giving YiFei Zhu any attribution and you > instead attribute the whole idea to Jann Horn: > > https://lkml.kernel.org/r/20200923232923.3142503-5-keescook@chromium.org You're missing that I did suggest the BPF emulation approach (with code very similar to Kees' current code) back in June: https://lore.kernel.org/lkml/CAG48ez1p=dR_2ikKq=xVxkoGg0fYpTBpkhJSv1w-6BG=76PAvw@mail.gmail.com/