Netdev List
 help / color / mirror / Atom feed
From: Chuyf26 <Chuyf26@linux.alibaba.com>
To: horms@kernel.org
Cc: xeb@mail.ru, netdev@vger.kernel.org
Subject: Re: [PATCH] pptp: reject payloads shorter than the PPP protocol field
Date: Fri, 21 Aug 2026 17:42:08 +0800	[thread overview]
Message-ID: <178730532802.474692.15922523828621281026@linux.alibaba.com> (raw)
In-Reply-To: <20260821092618.GF265046@horms.kernel.org>

Simon,

you are right. I double-checked the arithmetic: when len == 1,
pskb_may_pull(skb, 1 + len) only guarantees 2 bytes, so p[1] is read
one byte past the validated area, but the pre-existing
len < p[1] + 2 check rejects the frame for every possible value of
that byte, and the len < 2 clause only hides the read behind
short-circuit evaluation. There is no control-flow change, so this is
hardening at best rather than a fix, and given the read stays inside
the skb allocation I am withdrawing this patch instead of resubmitting
it for net-next without a Fixes tag.

The point in finding 2 about the p[1] / p[2] mismatch is valid, but
as there is no memory-safety consequence I do not plan to pursue it
here either.

The pptp patch from the same series is addressed in a separate reply.

Chuyf26

      reply	other threads:[~2026-08-21  9:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-18 16:21 [PATCH] pptp: reject payloads shorter than the PPP protocol field Chuyf26
2026-08-21  9:07 ` Simon Horman
2026-08-21  9:42   ` Chuyf26
2026-08-21  9:26 ` Simon Horman
2026-08-21  9:42   ` Chuyf26 [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=178730532802.474692.15922523828621281026@linux.alibaba.com \
    --to=chuyf26@linux.alibaba.com \
    --cc=horms@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=xeb@mail.ru \
    /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