netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sabrina Dubroca <sd@queasysnail.net>
To: Jakub Kicinski <kuba@kernel.org>
Cc: Hangyu Hua <hbh25y@gmail.com>,
	borisp@nvidia.com, john.fastabend@gmail.com, davem@davemloft.net,
	edumazet@google.com, pabeni@redhat.com, ilyal@mellanox.com,
	aviadye@mellanox.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] net: tls: fix possible info leak in tls_set_device_offload()
Date: Fri, 24 Feb 2023 21:22:20 +0100	[thread overview]
Message-ID: <Y/kcfM5jWrQhdYFR@hog> (raw)
In-Reply-To: <20230224105729.5f420511@kernel.org>

2023-02-24, 10:57:29 -0800, Jakub Kicinski wrote:
> On Fri, 24 Feb 2023 18:28:39 +0800 Hangyu Hua wrote:
> > After tls_set_device_offload() fails, we enter tls_set_sw_offload(). But
> > tls_set_sw_offload can't set cctx->iv and cctx->rec_seq to NULL if it fails
> > before kmalloc cctx->iv. It is better to Set them to NULL to avoid any
> > potential info leak.
> 
> Please show clear chain of events which can lead to a use-after-free 
> or info leak. And if you can't please don't send the patch.

Sorry, I thought in this morning's discussion Hangyu had agreed to
remove all mentions of possible info leak while sending v2, since we
agreed [1] that this patch didn't fix any issue, just that it looked
more consistent, as tls_set_sw_offload NULLs iv and rec_seq on
failure. We can also drop the patch completely. Anyway since net-next
is closed, I should have told Hangyu to wait for 2 weeks.

[1] https://lore.kernel.org/all/310391ea-7c71-395e-5dcb-b0a983e6fc93@gmail.com/

-- 
Sabrina


  reply	other threads:[~2023-02-24 20:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-24 10:28 [PATCH v2] net: tls: fix possible info leak in tls_set_device_offload() Hangyu Hua
2023-02-24 18:57 ` Jakub Kicinski
2023-02-24 20:22   ` Sabrina Dubroca [this message]
2023-02-27  5:53     ` Hangyu Hua

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=Y/kcfM5jWrQhdYFR@hog \
    --to=sd@queasysnail.net \
    --cc=aviadye@mellanox.com \
    --cc=borisp@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hbh25y@gmail.com \
    --cc=ilyal@mellanox.com \
    --cc=john.fastabend@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).