kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Colin King <colin.king@canonical.com>
Cc: Jozsef Kadlecsik <kadlec@netfilter.org>,
	Florian Westphal <fw@strlen.de>,
	"David S . Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	netfilter-devel@vger.kernel.org, coreteam@netfilter.org,
	netdev@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] netfilter: nf_tables: Fix dereference of null pointer flow
Date: Fri, 2 Jul 2021 02:56:48 +0200	[thread overview]
Message-ID: <20210702005648.GC29227@salvia> (raw)
In-Reply-To: <20210624195718.170796-1-colin.king@canonical.com>

On Thu, Jun 24, 2021 at 08:57:18PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
> 
> In the case where chain->flags & NFT_CHAIN_HW_OFFLOAD is false then
> nft_flow_rule_create is not called and flow is NULL. The subsequent
> error handling execution via label err_destroy_flow_rule will lead
> to a null pointer dereference on flow when calling nft_flow_rule_destroy.
> Since the error path to err_destroy_flow_rule has to cater for null
> and non-null flows, only call nft_flow_rule_destroy if flow is non-null
> to fix this issue.

Applied, thanks.

      parent reply	other threads:[~2021-07-02  0:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-24 19:57 Colin King
2021-06-25  9:59 ` Dan Carpenter
2021-06-25 10:20   ` Pablo Neira Ayuso
2021-06-25 10:33     ` Dan Carpenter
2021-06-25 10:06 ` AW: " Walter Harms
2021-06-25 10:21   ` Pablo Neira Ayuso
2021-07-02  0:56 ` Pablo Neira Ayuso [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210702005648.GC29227@salvia \
    --to=pablo@netfilter.org \
    --cc=colin.king@canonical.com \
    --cc=coreteam@netfilter.org \
    --cc=davem@davemloft.net \
    --cc=fw@strlen.de \
    --cc=kadlec@netfilter.org \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=netfilter-devel@vger.kernel.org \
    --subject='Re: [PATCH][next] netfilter: nf_tables: Fix dereference of null pointer flow' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).