From: Steffen Klassert <steffen.klassert@secunet.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: <netdev@vger.kernel.org>, David George <David.George@sophos.com>,
"Markus Trapp" <markus.trapp@secunet.com>
Subject: Re: [PATCH] xfrm: Remove inner/outer modes from input path
Date: Tue, 6 Jun 2023 12:45:29 +0200 [thread overview]
Message-ID: <ZH8OSd1ElPIKCFa+@gauss3.secunet.de> (raw)
In-Reply-To: <ZAr3rc+QvKs50xkm@gondor.apana.org.au>
Hi Herbert,
On Fri, Mar 10, 2023 at 05:26:05PM +0800, Herbert Xu wrote:
...
> @@ -369,17 +366,12 @@ static int xfrm_prepare_input(struct xfrm_state *x, struct sk_buff *skb)
> return -EAFNOSUPPORT;
> }
>
> - if (x->sel.family == AF_UNSPEC) {
> - inner_mode = xfrm_ip2inner_mode(x, XFRM_MODE_SKB_CB(skb)->protocol);
> - if (!inner_mode)
> - return -EAFNOSUPPORT;
> - }
> -
> - switch (inner_mode->family) {
> - case AF_INET:
> + switch (XFRM_MODE_SKB_CB(skb)->protocol) {
> + case IPPROTO_IPIP:
> + case IPPROTO_BEETPH:
the assumption that the L4 protocol on BEET mode can be
just IPIP or BEETPH seems not to be correct. One of
our testcaces hit the second WARN_ON_ONCE() in
xfrm_prepare_input. In that case the L4 protocol
is UDP. Looks like we need some other way to
dertermine the inner protocol family.
next prev parent reply other threads:[~2023-06-06 10:45 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-10 9:26 [PATCH] xfrm: Remove inner/outer modes from input path Herbert Xu
2023-03-15 11:05 ` Steffen Klassert
2023-06-06 10:45 ` Steffen Klassert [this message]
2023-06-07 8:38 ` [PATCH] xfrm: Use xfrm_state selector for BEET input Herbert Xu
2023-06-07 8:47 ` Steffen Klassert
2023-06-07 8:50 ` Herbert Xu
2023-06-07 8:57 ` Steffen Klassert
2023-06-07 9:04 ` Herbert Xu
2023-06-12 11:46 ` Steffen Klassert
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=ZH8OSd1ElPIKCFa+@gauss3.secunet.de \
--to=steffen.klassert@secunet.com \
--cc=David.George@sophos.com \
--cc=herbert@gondor.apana.org.au \
--cc=markus.trapp@secunet.com \
--cc=netdev@vger.kernel.org \
/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).