All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steffen Klassert <steffen.klassert@secunet.com>
To: Andrii Tereshchenko <opensource@andrii.net>
Cc: Herbert Xu <herbert@gondor.apana.org.au>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@kernel.org>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Simon Horman <horms@kernel.org>,
	Christian Hopps <chopps@labn.net>,
	Fernando Fernandez Mancera <fmancera@suse.de>,
	Willem de Bruijn <willemb@google.com>,
	Piyus Kedia <piyus@iiitd.ac.in>, <netdev@vger.kernel.org>,
	<ipsec@lists.linux.dev>, <linux-kernel@vger.kernel.org>,
	<stable@vger.kernel.org>
Subject: Re: [PATCH ipsec v2] xfrm: iptfs: make room before copying a continuation in reassembly
Date: Fri, 27 Nov 2026 10:23:53 +0100	[thread overview]
Message-ID: <awlMKdcVSQEShHlw@gauss4> (raw)
In-Reply-To: <e417c7f2-eaee-4fb0-b365-65cd521efd6b@mid.andrii.net>

On Sun, Nov 22, 2026 at 05:09:25AM -0800, Andrii Tereshchenko wrote:
> When iptfs_reassem_cont() cannot share a continuation as page frags, it
> linearizes the in-progress skb and copies the data in with skb_put(),
> without checking the tailroom. An skb started by iptfs_pskb_add_frags()
> has little room after linearizing, so a larger continuation panics the
> kernel in softirq:
> 
>   skbuff: skb_over_panic: ... len:2884 put:1442 ... end:0x6c0 dev:eth1
>   kernel BUG at net/core/skbuff.c:215!
>   Call Trace:
>    <IRQ>
>    skb_put.cold+0x1f/0x1f
>    iptfs_reassem_cont+0x242/0x760
>    iptfs_input_ordered+0x382/0x3e0
>    iptfs_input+0x24d/0x630
>    xfrm_input+0x12a5/0x29f0
> 
> After linearizing, grow the head if the rest of the inner packet does
> not fit, and abandon the reassembly if that fails.
> 
> Made with an AI coding assistant, reviewed by the submitter.
> 
> Fixes: 5f2b6a909574 ("xfrm: iptfs: add skb-fragment sharing code")
> Fixes: 0b352f83cabf ("xfrm: iptfs: fix skb_put() panic on non-linear skb during reassembly")
> Reported-by: Piyus Kedia <piyus@iiitd.ac.in>
> Closes: https://lore.kernel.org/all/20261119142308.3272570-1-piyus@iiitd.ac.in/
> Link: https://lore.kernel.org/all/20260908224855.1591147-1-kuba@kernel.org/
> Cc: stable@vger.kernel.org
> Signed-off-by: Andrii Tereshchenko <opensource@andrii.net>

Applied, thanks a lot!

      parent reply	other threads:[~2026-11-27  9:24 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-22 13:09 [PATCH ipsec v2] xfrm: iptfs: make room before copying a continuation in reassembly Andrii Tereshchenko
2026-11-24 10:06 ` Fernando Fernandez Mancera
2026-11-27  9:23 ` Steffen Klassert [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=awlMKdcVSQEShHlw@gauss4 \
    --to=steffen.klassert@secunet.com \
    --cc=chopps@labn.net \
    --cc=davem@davemloft.net \
    --cc=edumazet@kernel.org \
    --cc=fmancera@suse.de \
    --cc=herbert@gondor.apana.org.au \
    --cc=horms@kernel.org \
    --cc=ipsec@lists.linux.dev \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=opensource@andrii.net \
    --cc=pabeni@redhat.com \
    --cc=piyus@iiitd.ac.in \
    --cc=stable@vger.kernel.org \
    --cc=willemb@google.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.