Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3203641ybb; Mon, 13 Apr 2020 03:01:45 -0700 (PDT) X-Google-Smtp-Source: APiQypI3Sjf3sd0kc+YTd4v0iP4I3/atIWf+SIEO6uc7Ub7KrOZrTtWxbF8SwZqjHZYamD4Y89HJ X-Received: by 2002:a17:906:7785:: with SMTP id s5mr14081648ejm.174.1586772105472; Mon, 13 Apr 2020 03:01:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586772105; cv=none; d=google.com; s=arc-20160816; b=Cuk3tw2WaLTyDblXrPwcipZjq37hZV42s3QJr7vaeFvzpQc1z01KPJhpIlNVkfnsuK AHwajYGOz8nbs+9YkkpaNBeQM5lJI+0Z8lDs9VbnnEoOIQ7kPaxP/frbxJIYlprWdixF +ZezcKzC+94d24aQKwYNcdQrutiVUzP6GYzxcZnOl1Q3qsmTB/3EfiiUaPPZt/6beJQ2 tswWVKDgFnf+PoAX8DaDA6s2mHvXc7dpK14HZu2b5zuqxDos9g8cFV1gm30iyMLgYM53 6HJOJ8cnNSYgwPMV86S7ju/SxvcRpYRLxjDeowQO8xvmYcviqzEbXOXneUnJKJgAi5pI Rzrg== 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=U9xxTNwOkKebXQdrj7e3IgHeXx4Dib7AVZXHCVRHOH8=; b=fKdu5EVHvHdyXxoRGV4Ld6XIrca64DVnxjakGDmKWDXtwiRmryaxhyq8GckN0jfAVg VHblesvx9+ej3muf/4E+7YF1xgqfAbQcU4cAzPJeAdPzznZH+SOI3R/25X40hFMVAuQH w+neWKVjk8bAy/SL7lpaFu5O8weODpboecqq6hH9BztAWStHIlRUA/mfNHksRwhQD4wY LpQACMN/Jx0HY0Idv3/xFdwE9LtdQ7BtWgZHb7qYvMGprgByWqEObuAIUG55ev8n5Qie aFH1iYWa0BO1BxfaIvOukr6SZRc3mIwVYcD3v1NkDHLnsi8Nl15KetRHTMOE38qe84j9 a1Pg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=unKP9RXb; spf=pass (google.com: best guess record for 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ce2si6946088edb.26.2020.04.13.03.01.22; Mon, 13 Apr 2020 03:01:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for 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=@gmail.com header.s=20161025 header.b=unKP9RXb; spf=pass (google.com: best guess record for 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728364AbgDMJ3m (ORCPT + 99 others); Mon, 13 Apr 2020 05:29:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33238 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1727886AbgDMJ3l (ORCPT ); Mon, 13 Apr 2020 05:29:41 -0400 X-Greylist: delayed 304 seconds by postgrey-1.27 at vger.kernel.org; Mon, 13 Apr 2020 05:29:41 EDT Received: from mail-il1-x144.google.com (mail-il1-x144.google.com [IPv6:2607:f8b0:4864:20::144]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B2511C008617 for ; Mon, 13 Apr 2020 02:24:37 -0700 (PDT) Received: by mail-il1-x144.google.com with SMTP id t11so7983987ils.1 for ; Mon, 13 Apr 2020 02:24:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=U9xxTNwOkKebXQdrj7e3IgHeXx4Dib7AVZXHCVRHOH8=; b=unKP9RXbUz90EHX5WxmTHsCCH9XxfAAbFg3/LOMgsay5e07ojds+iWLocS9bocDjY5 tF0EHr8PudIxMzaJUrJsstirJaTCRARtPuGZErdINVTgp/tIVjm6B+9v8z43zZRgOIlR +BBtl8OihBbqPgRdtuqFmSVfk/Uk5wnwNSQoSrfuy/mFosmpBsVUIlAOEV3trFpyultB 2eUehxYDp0vPgi4JPqyHdocBceIejRErvV9FbU/tCjto5YWzg+u/wh+eyEb8hs/Pe5ss PB12xiNU6ldMIz/e2wjYRL9KxBXMJMPnXx99JlgwhLnjcNV5Pl8yVhy980/PsVGC8BQU h7oA== 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=U9xxTNwOkKebXQdrj7e3IgHeXx4Dib7AVZXHCVRHOH8=; b=r5vPFroo9eU7/E6pLbF0mPymiquXOdfs/6twms2Lii7E/O9KJYBH9DdZ1zVDURXFGo jCDeg7Z8l+0LiBezKtUF3gp7AzcKGP1rEKoC6mskCvu6/8sc/i/6/SYgXoh4o99ne80f YlY8jsOFU0CFiK2gUUu2jQ6RDJqkiglWE85+GdnVN+qezgDatJOEUQXniovu72fWn2x9 kFgAkVB+9B33iscBj1UuAi5FfnZDuIW1LkR7RbmC50JHlDMBXCiECOlHqfBfXdaou/Fq WJw5wh+5IOQ6NP8LxU9mwW60OzgepV5/EPW5t/7IRj5MT/+tY7WGc/6FFVnJFK6DW3/m xvMA== X-Gm-Message-State: AGi0PuaJ0eBTfMvpPX9Wm45+jKDSI09U6ht06al5g4c63966gqOkcS9Z dkmteQHIQSom4CZqpl7ArFVBN5VhHk3MPrvxoN4= X-Received: by 2002:a92:d2c5:: with SMTP id w5mr15430488ilg.143.1586769876957; Mon, 13 Apr 2020 02:24:36 -0700 (PDT) MIME-Version: 1.0 References: <20200219171225.5547-1-idryomov@gmail.com> <20200408150643.GD3676135@smile.fi.intel.com> <0fd21b6115b647baac23ee926b4c76f8@AcuMS.aculab.com> In-Reply-To: <0fd21b6115b647baac23ee926b4c76f8@AcuMS.aculab.com> From: Ilya Dryomov Date: Mon, 13 Apr 2020 11:24:30 +0200 Message-ID: Subject: Re: [PATCH v2] vsprintf: don't obfuscate NULL and error pointers To: David Laight Cc: Linus Torvalds , Andy Shevchenko , Rasmus Villemoes , Petr Mladek , Linux Kernel Mailing List , Steven Rostedt , Randy Dunlap , Kees Cook , Sergey Senozhatsky , "Tobin C . Harding" 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 Fri, Apr 10, 2020 at 11:40 AM David Laight wrote: > > From: Linus Torvalds > > Sent: 08 April 2020 17:23 > > On Wed, Apr 8, 2020 at 8:08 AM Andy Shevchenko > > wrote: > > > > > > For the better understanding the current state of affairs I suggest to respin > > > new version after rc1 and we will see again. > > If the hash of a pointer ends up being one of the values that > wouldn't be hashed, perhaps it should be hashed again. > That will remove any possible confusion. Hi David, That seems sensible, but out of scope of this patch IMO. My goal was to fix a 5.2 regression for NULL pointers. I tacked on IS_ERR pointers because they aren't actual addresses either and hashing them makes zero sense. Although simple to implement, I'm afraid that introducing additional rounds of hashing would drag this patch further (it's already got bogged down in the test suite structure discussion). Thanks, Ilya