Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1404100pxb; Wed, 2 Feb 2022 04:20:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJx7gchVgq2tyYQpMtCyhbAEUTMNEU/V2ez/ztECXNLSqkZpU/i7KtYttqgxzn3CT/S2ZQyG X-Received: by 2002:a17:90b:1e07:: with SMTP id pg7mr7734485pjb.97.1643804425217; Wed, 02 Feb 2022 04:20:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643804425; cv=none; d=google.com; s=arc-20160816; b=o2zpQVQIvuof2M3kys5274v6Q5zexSzUjWbs5MDP2u4jqID+8ULJisPPD1JrHltvZ3 kv9w3nJXJgzXP/OHmadKJsXJjNnB4RQTGVpNLtNQcYrFmckDD3CT9aLZRB94eB+OFofT rIdWU6odilyW2XHpJItWkl5uYm6JfPMC/N3KSLJRNzi8uiyEAl6ymWr7ERYeiu5xnhWH cZITrCFZBR0ThcDK2rvUpIxC+Iloe4l2aYollJeXUqn2pP4cZL+L/jFVtfYj1c+N4H4s 6BPKGfEUSKs0OK4ge347MWNXbih/jkOaDrhdzQLzjNDZbcSHdvHWomPG7iF3UmFQsZBy 7lTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=RvL9QdjkC+SphkFVEijW2nOqkzsznbZtJEI24EWO4ow=; b=I0RFAk1GpyL9z8cRrjO5tKdsFPzzbLtbEG8eQGBYaSkdAHcJGLKHJcwTr/MXKUkWJS imUiP4Xp+mGt1qc0bTGgrg2ah3s0Jg1gcdmEDKSr9UNl2IWt1HnK+dSn2XBxUtIcDyJR RNd80eEPbg8WP52boLClF2MCmkD3Bz7MCcIqnYQ6wfCtY7jWQd7BlKSv6btl3SpxhgLH 7a8RA2TG+15HGO/VA4A9twy2yZvLmY7qFFNgjxb+wArLVbP0TX+UnJ7u3ijoarks2asx MlICIj+87OU36aSniMhrCd9rlC06eDuCJXiqUKd09sJgPyxptNbRzwA/kFVhe/HBegEb pwKQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ICn0cMvL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q11si17041009pld.501.2022.02.02.04.20.13; Wed, 02 Feb 2022 04:20:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ICn0cMvL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238627AbiBAN2f (ORCPT + 99 others); Tue, 1 Feb 2022 08:28:35 -0500 Received: from dfw.source.kernel.org ([139.178.84.217]:59008 "EHLO dfw.source.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238612AbiBAN2c (ORCPT ); Tue, 1 Feb 2022 08:28:32 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 96D8161550; Tue, 1 Feb 2022 13:28:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8DFFAC340EB; Tue, 1 Feb 2022 13:28:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1643722112; bh=SIqq9crD10sgnkKKMFFcJOxkf1QKasn6QR3NIP9XRHc=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ICn0cMvLVZK2SakKeULzNMwWIdXdNq/5aKuMcpBGA4X6aJF7QLNnM5KFiK9mIqYY8 NnLMG0rJOy7M4k6eXEccc5PRP3P91zggBq/nB193GuQWAh65YjUx2AsugxbMeeQ1QO p1w0OcLjH6WoSqytzRFUYhIhi4J1tK1GKlzbPqMFGu23dSVhguke6uAl5gF+H9SuIu zOmRYRXAwt2wmf62l77l8hENhS/nDS93RCb0y64/PtkZzlrCn/SPvP97haLN+KjYU+ QTx2TeoBBWSedKJTAMMK85Ykxgh4tlVPtELmBkxj5cFay0k5AlUESIq7zvV+uMpvPz MSEIScwOYScew== Date: Tue, 1 Feb 2022 14:28:25 +0100 From: Christian Brauner To: Andrew Morton Cc: Matthew Wilcox , kernel test robot , Kees Cook , Ariadne Conill , 0day robot , Michael Kerrisk , Rich Felker , Eric Biederman , Alexander Viro , LKML , lkp@lists.01.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, stable@vger.kernel.org Subject: Re: [fs/exec] 80bd5afdd8: xfstests.generic.633.fail Message-ID: <20220201132825.zgl3fhnmhex5hcaw@wittgenstein> References: <20220127000724.15106-1-ariadne@dereferenced.org> <20220131144352.GE16385@xsang-OptiPlex-9020> <20220131150819.iuqlz3rz6q7cheap@wittgenstein> <20220131153707.oe45h7tuci2cbfuv@wittgenstein> <20220131161415.wlvtsd4ecehyg3x5@wittgenstein> <20220131171344.77iifun5wdilbqdz@wittgenstein> <20220131135940.20790cff1747e79dd855aaf4@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20220131135940.20790cff1747e79dd855aaf4@linux-foundation.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jan 31, 2022 at 01:59:40PM -0800, Andrew Morton wrote: > On Mon, 31 Jan 2022 18:13:44 +0100 Christian Brauner wrote: > > > > in other words, the changes that you see CMD_ARGS[0] == NULL for > > > execveat() seem higher than for path-based exec. > > > > > > To counter that we should probably at least update the execveat() > > > manpage with a recommendation what CMD_ARGS[0] should be set to if it > > > isn't allowed to be set to NULL anymore. This is why was asking what > > > argv[0] is supposed to be if the binary doesn't take any arguments. > > > > Sent a fix to our fstests now replacing the argv[0] as NULL with "". > > As we hit this check so quickly, I'm thinking that Ariadne's patch > "fs/exec: require argv[0] presence in do_execveat_common()" (which > added the check) isn't something we'll be able to merge into mainline? Not in the originally envisioned form. But I think Kees patch to make a argv[0] the empty string when it's NULL has a better chance of surviving.