Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp5134683pxj; Wed, 9 Jun 2021 09:55:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzDNz4ukHvjXs3XcDPuogBYqe/wkso2GJu+/eqe2/pycGtF7JUf7G9mTvbJ+jjgSASoYFgZ X-Received: by 2002:a17:906:32c3:: with SMTP id k3mr777823ejk.95.1623257747037; Wed, 09 Jun 2021 09:55:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623257747; cv=none; d=google.com; s=arc-20160816; b=JWvxPkkAIm5Zqo3C4XDh6WSvFKJjm7d1LoAWOFYKcp8eZuaf1sRP5Dtjprjc0Nfstk FtsPzx2+34wc7PZt6xfwBzqAPiGif+cBeBJa6WfcDUDRl0znVUZb+ZawXqFvEl/4VONF xWCjktO4fB27B5J2P+MIZZlDyn7U3pTtILtJ3SDwWKjF9VHh+UX02l2L7tPuICR4BNyQ qgSKgP+C8qHG/f+8hkRnjN6eVlzvCpYDUqOQmts0t182/ZFznEG3DkoC4qbQycmgcoRI 7JOo+rFFbyDr4iaNrDgALntCCRsgfbkYn5WNhMlrsfFHZAqGw86ZG8LKU6tcDFC1Rpyf QQJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:ironport-sdr:ironport-sdr; bh=fLH9Bsf1+l2dTaHz6Z1H+5G8b7MUHbln8YNO1ley2Nc=; b=xUxHScHw7AY3goZl4nWsyqLtPV/Ui6W9soiJgfHT/M52a0+6biud1ZB9IwnaOua3vd 3ToHk0+Pxpy35WSjb5Bqem3yH3s83xlLOqJ0FM+bQC0pH8eI5zxb4xCX7uI2KueLbi7P GTNDUBAxaN3hkAvphVP7uCuSEcw3NrxQ8SH9qtdHo7AdpN+ckBqSBaAYaQ8Dn6gMK/pi CzphRnFj7lu+9DJ5OW+hdRZmO+Mi+Tck+1LFVpVjGu76WHplIJXy8TH6UM+eKyFOCoM9 GaTIgzby4ZnpS0GNvBbVOtKEWRnhJfCQAO2M2OE3isi56biaB9lXEueXZNPlOJfcuu3C b74g== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j10si199536edw.560.2021.06.09.09.55.23; Wed, 09 Jun 2021 09:55: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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235467AbhFHXkN (ORCPT + 99 others); Tue, 8 Jun 2021 19:40:13 -0400 Received: from mga04.intel.com ([192.55.52.120]:25117 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234187AbhFHXkM (ORCPT ); Tue, 8 Jun 2021 19:40:12 -0400 IronPort-SDR: PhVfYU3yM+kKGfCbOtWah/c4y+TTHybZCU1QC/l4xGNJS9Tsdqv4F+Y9vh4yf7pt76JsfAyJ2U O3AYQrc9uweQ== X-IronPort-AV: E=McAfee;i="6200,9189,10009"; a="203113719" X-IronPort-AV: E=Sophos;i="5.83,259,1616482800"; d="scan'208";a="203113719" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Jun 2021 16:38:16 -0700 IronPort-SDR: pE4bdvjF0J9Yr2v3Y5b0EYAhXyF61Gs96zOXtSka7ND8veuaNykb0Auifm2a4kdYM6xKQUkwk/ irwRg3JJ0msA== X-IronPort-AV: E=Sophos;i="5.83,259,1616482800"; d="scan'208";a="551784529" Received: from akleen-mobl1.amr.corp.intel.com (HELO [10.209.24.11]) ([10.209.24.11]) by orsmga004-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Jun 2021 16:38:15 -0700 Subject: Re: [PATCH v8 0/8] Fork brute force attack mitigation To: Kees Cook , John Wood Cc: Jann Horn , Jonathan Corbet , James Morris , "Serge E. Hallyn" , Shuah Khan , Thomas Gleixner , Ingo Molnar , Borislav Petkov , x86@kernel.org, "H. Peter Anvin" , Arnd Bergmann , valdis.kletnieks@vt.edu, Greg Kroah-Hartman , Randy Dunlap , Andrew Morton , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-security-module@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-arch@vger.kernel.org, linux-hardening@vger.kernel.org, kernel-hardening@lists.openwall.com References: <20210605150405.6936-1-john.wood@gmx.com> <202106081616.EC17DC1D0D@keescook> From: Andi Kleen Message-ID: Date: Tue, 8 Jun 2021 16:38:15 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.10.2 MIME-Version: 1.0 In-Reply-To: <202106081616.EC17DC1D0D@keescook> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/8/2021 4:19 PM, Kees Cook wrote: > On Sat, Jun 05, 2021 at 05:03:57PM +0200, John Wood wrote: >> [...] >> the kselftest to avoid the detection ;) ). So, in this version, to track >> all the statistical data (info related with application crashes), the >> extended attributes feature for the executable files are used. The xattr is >> also used to mark the executables as "not allowed" when an attack is >> detected. Then, the execve system call rely on this flag to avoid following >> executions of this file. > I have some concerns about this being actually usable and not creating > DoS situations. For example, let's say an attacker had found a hard-to-hit > bug in "sudo", and starts brute forcing it. When the brute LSM notices, > it'll make "sudo" unusable for the entire system, yes? > > And a reboot won't fix it, either, IIUC. > The whole point of the mitigation is to trade potential attacks against DOS. If you're worried about DOS the whole thing is not for you. -Andi