Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1370154pxk; Thu, 10 Sep 2020 13:41:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwDeCaUiKqjTuX5godyHgXnYRcYxJiPNrSBFgwwQWmyK53gla603rg7LmIXxX5kFnIvuing X-Received: by 2002:a05:6402:17f6:: with SMTP id t22mr11099708edy.374.1599770507314; Thu, 10 Sep 2020 13:41:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599770507; cv=none; d=google.com; s=arc-20160816; b=HG+zOjrcdATFoqcec41FkWiPBdHSG/SAHWN+2j39OMhE8a8DiNRIXd3eV6icfyjEqy +L7xn8KXc92ZUO9DtT5Xu6urG9Yj3t9PPHeh/xWTs2/YD0xYL+QyaBDLQl1eZMuLQ8U3 XbbblEvu+7BGQm0rh5WGZdZEa8wvzSl0iwGaoI744tHWBLWPCMhf8tCZeXsCr38YVmeX TcpSkdlojj8XwCgFxWnDiaKLKQktzLc8vBBZxI4IMs1ZQ6z6UgylTGxZB6h8XHpwpwFw 7EQ6eqhTL4ph7aWVjPl3n5uUyEq5z8cRFsGV/yDwQpbttZFCWfqDYFwLWBEVHCHxMYe3 i9lQ== 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 :in-reply-to:references:mime-version:dkim-signature; bh=QYmngQGxhwrP1IO10+U44hIuDR+Bh29FacWTWPCzifs=; b=aICAp27ppnwTVXakoAM8YKjloU6UbFvAHV3VykFRicx5nX9HNy6eR5b/fSg8TfYFWk TqX4mcAn30aUy4OoS53MuTIms6jELIDYqPaGTTjoSngNpBc312HOJ5zqOcP/EveBMbTY km1WNlpvXqoEUDQsUv38Ul7EfU+P1+H0TN2rIIEJy9YDQZHsKvo/H5Ejr2rfAFevyxsS t9doLLYmyVFs/BtqS6L/1BpGgFOI059PYemU7nmYGsEfzlGP/sOrH5WA/zwLle86Zd49 l/VQVptQ80zWjDLYGZkFsfBxK5Qg6294/c8Z7aN/4sKFM4ZTRh34Zb4Je+bVAyvGMN+l Qcuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=WH2gIvD2; 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 h19si4232482ejl.253.2020.09.10.13.41.24; Thu, 10 Sep 2020 13:41:47 -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=WH2gIvD2; 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 S1726962AbgIJUkg (ORCPT + 99 others); Thu, 10 Sep 2020 16:40:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57642 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727030AbgIJUjh (ORCPT ); Thu, 10 Sep 2020 16:39:37 -0400 Received: from mail-ed1-x543.google.com (mail-ed1-x543.google.com [IPv6:2a00:1450:4864:20::543]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B15B5C0613ED for ; Thu, 10 Sep 2020 13:39:32 -0700 (PDT) Received: by mail-ed1-x543.google.com with SMTP id n22so7734033edt.4 for ; Thu, 10 Sep 2020 13:39:32 -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=QYmngQGxhwrP1IO10+U44hIuDR+Bh29FacWTWPCzifs=; b=WH2gIvD2kocNW47TzoJUq8vy8koxj0ikTiqTurIt6Osqva8P4NIsbGtJVGwywUIjkq xe3qkruoqIuEPaS3xmqhN2h7V3FGdVjN/fZNXtAtjbUs+ii6wOWOxYBwlihrbKA6Dsi2 ZcxxkAAiqBfwAJnSmslWIncB3hpPqqLBsQnucMZPZcNa3susHR1gFRdjKlEQ6Zwl4evT Ngj6/THEyDfAL+bxEhBtLcLnD1Efcq5a03Byz8i2VKTt0P9PSzdVa+iwn8BOcmkqFZjj WKCR+bEgC/b8wFZGdDbKxyU2GcFt1zleojRTJ6mzpqrmZfP30xuKihxrC7oSbqE+O1e4 z6+A== 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=QYmngQGxhwrP1IO10+U44hIuDR+Bh29FacWTWPCzifs=; b=lJtCu1sJpEtCNwfD0as1pPC9kFoODCTuZW01uG/r5GYHl269hcwobpriDxJShWulhX MszPjMaomfVY3/ISOu2AjzeihrNhPn0CKPB9EmupCIJC0qGyfh1bjvfOJyPjNWF5xWR4 b9LAxEXvWZfF0As1GO/rC/b+iBt++3PHVjFIa1G1rKiEsvrpiBIfI8G6uWD2zUggfQoS DP7M9L3iLIjLvIQAqJCDveF0xS3nosJ6oaOABpjRVf3ZZsrGaBflPb/u12adsj8iv2JA 2ivBcbv46AaMIqndw4hekKcuSzWov4rzuWouVsUwjWuXmbXvnKRvSqoeAvZzGOtrAUMp WJRA== X-Gm-Message-State: AOAM533SdfQ3vwTeretcn6n5ltAE1AkQObkRu8ALeQVwIXmqvT5XApIk Da7nxTO/Pli9REqI241hZ2vlf+BqaJQZVLUvbJeFWA== X-Received: by 2002:a05:6402:7d2:: with SMTP id u18mr11556708edy.69.1599770370678; Thu, 10 Sep 2020 13:39:30 -0700 (PDT) MIME-Version: 1.0 References: <20200910202107.3799376-1-keescook@chromium.org> In-Reply-To: <20200910202107.3799376-1-keescook@chromium.org> From: Jann Horn Date: Thu, 10 Sep 2020 22:39:04 +0200 Message-ID: Subject: Re: [RESEND][RFC PATCH 0/6] Fork brute force attack mitigation (fbfam) To: Kees Cook , John Wood Cc: Kernel Hardening , Matthew Wilcox , Jonathan Corbet , Alexander Viro , Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Luis Chamberlain , Iurii Zaikin , James Morris , "Serge E. Hallyn" , linux-doc@vger.kernel.org, kernel list , linux-fsdevel , linux-security-module 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 Thu, Sep 10, 2020 at 10:21 PM Kees Cook wrote: > [kees: re-sending this series on behalf of John Wood > also visible at https://github.com/johwood/linux fbfam] [...] > The goal of this patch serie is to detect and mitigate a fork brute force > attack. > > Attacks with the purpose to break ASLR or bypass canaries traditionaly use > some level of brute force with the help of the fork system call. This is > possible since when creating a new process using fork its memory contents > are the same as those of the parent process (the process that called the > fork system call). So, the attacker can test the memory infinite times to > find the correct memory values or the correct memory addresses without > worrying about crashing the application. For the next version of this patchset, you may want to clarify that this is intended to stop brute force attacks *against vulnerable userspace processes* that fork off worker processes. I was halfway through the patch series before I realized that.