Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp4587746pxf; Tue, 23 Mar 2021 14:38:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJynxDsyxI9b4soS+3G8vVT1DiEaXWogXiFuF3BlzjxdrDV/sjsmOfTom7IbjJrZfbmrMGK+ X-Received: by 2002:a17:907:3e8a:: with SMTP id hs10mr231073ejc.267.1616535507362; Tue, 23 Mar 2021 14:38:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616535507; cv=none; d=google.com; s=arc-20160816; b=g6DkH/Bzt8c0gdzYePVfnYnzGx7/MAo+hTxXwe8FdbVUJmym9qIE7nsUSLzPqZs7dG nKWNTcOdVVgllYSG2tS2bXxst+05ia1+itVDwjQVUjBI6FvwMfkvzQUa24GBpvxqKfic hdyDOwjUzW014SdmfIGbWfXRmHQ2MOstJ7xHhd7YambY2+WLGymzpHWLRM42USFVe8IY cR1QrWCOBXCbFLZbk1Bjq8h9OiDApDM0/dyKV4Bp5sEjb+WGwfBt2R8/TrFq/wwXBj0o PKPndRN4aaTNpxvROoGRSVLBx3wWNjajcZxLLUpuFVxpikAUgIjvhlU+zIHB4IlxYcVf 2WDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=OjXjh3kEEQNu1FZuJSoJFOAIt7EB7WXJbk8JwYEzSKY=; b=sMsmImfjs3w9zLm5k52mWHL71LefI7d+PMLum8W0+iNeXfVTdRuMKG75pghin3mURw hXBaHxw+t0V9qXDmqU//IbtkcOqD0tWGNBZ4jzoC/V8DsbCKXvK1+tCGqfIQyR+Thr/i ljey475wMZeh9JQbBzmUjZvY779UaPjns8ttQ84Vf/sYOsESf9fDZ0gAMInFkcOdnlJm ukC1Bv1Goq5VuQ+EQwMGl93GL7WHm2ljk1lIefUGITDihK2OMASE3Cysa6pTWIN4Dkrq f7Kr1BoHwxVqO5wD7wbmLKRJc4UPRQrBgbz+qh11LVCts1aR/BgTlGxAIPp1IC/98zNH 7NiA== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h9si156740edv.190.2021.03.23.14.38.03; Tue, 23 Mar 2021 14:38:27 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233558AbhCWVhE (ORCPT + 99 others); Tue, 23 Mar 2021 17:37:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57206 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233464AbhCWVgf (ORCPT ); Tue, 23 Mar 2021 17:36:35 -0400 Received: from Chamillionaire.breakpoint.cc (Chamillionaire.breakpoint.cc [IPv6:2a0a:51c0:0:12e:520::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 40BD1C061574; Tue, 23 Mar 2021 14:36:34 -0700 (PDT) Received: from fw by Chamillionaire.breakpoint.cc with local (Exim 4.92) (envelope-from ) id 1lOohT-0007hU-Nr; Tue, 23 Mar 2021 22:36:31 +0100 Date: Tue, 23 Mar 2021 22:36:31 +0100 From: Florian Westphal To: Richard Guy Briggs Cc: Linux-Audit Mailing List , LKML , netfilter-devel@vger.kernel.org, Paul Moore , Eric Paris , Steve Grubb , Florian Westphal , Phil Sutter , twoerner@redhat.com, tgraf@infradead.org, dan.carpenter@oracle.com, Jones Desougi Subject: Re: [PATCH v3] audit: log nftables configuration change events once per table Message-ID: <20210323213631.GA27244@breakpoint.cc> References: <3d15fa1f0c54335f9258d90ea0d11050e780ba70.1616529248.git.rgb@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3d15fa1f0c54335f9258d90ea0d11050e780ba70.1616529248.git.rgb@redhat.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Richard Guy Briggs wrote: > nft_commit_notify(net, NETLINK_CB(skb).portid); > nf_tables_gen_notify(net, skb, NFT_MSG_NEWGEN); > nf_tables_commit_release(net); > > + nf_tables_commit_audit_log(&adl, net->nft.base_seq); This meeds to be before nf_tables_commit_release() call, afaics this function dereferences data structures that might be free'd already here.