All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Sunny73Cr <Sunny73Cr@protonmail.com>
Cc: Florian Westphal <fw@strlen.de>,
	"netfilter@vger.kernel.org" <netfilter@vger.kernel.org>
Subject: Re: Raw Payload Expressions - out of bounds write?
Date: Tue, 28 Jan 2025 01:37:06 +0100	[thread overview]
Message-ID: <20250128003706.GB29891@breakpoint.cc> (raw)
In-Reply-To: <R5drxaQptK9DK89Lt1TmFpDxo86ctD3Pu2WS4wEhXcOZq7yuVqJDxNIc2tZVIx1PJpF15g1AOJCW3gxNIPqlVH6ubbppDWQlzErAa4UP3UI=@protonmail.com>

Sunny73Cr <Sunny73Cr@protonmail.com> wrote:
> > Please elaborate as what is wrong here in listing 3.
> 
> Within the second line of the rule (@ih,80,16 set @ih,80,16 & 0x3f0 \)
> 
> The mask 0x3f0 equates to 1,008 in decimal.
> (3 * 16**2) + (15 * 16**1) + (0 * 16^0) = 1,008
> Here '**' indicates exponent.
> 
> 1,008 is far larger than the 34 bit range that I covered.

Sigh.  Why did you not say something like:

The mask is provided as '0x3f0' in the listing, but I had expected
0xfc0f, as only 6 bits should be cleared, but the mask KEEPS 6 bits.

It would have saved me a headache figuring out bug you refer to.
I am not a mind reader :-/

Use --debug=netlink, it looks like its a display bug.

I'll have a look.

  reply	other threads:[~2025-01-28  0:37 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-23  3:31 Raw Payload Expressions - out of bounds write? Sunny73Cr
2025-01-26 13:50 ` Florian Westphal
2025-01-26 18:08   ` Sunny73Cr
2025-01-28  0:37     ` Florian Westphal [this message]
2025-01-28  4:19       ` Sunny73Cr
2025-01-28 12:02         ` Jeremy Sowden
2025-01-28 12:12           ` Sunny73Cr
2025-01-28 12:41       ` Pablo Neira Ayuso
2025-01-30 11:27         ` Sunny73Cr
2025-02-08 20:26           ` Sunny73Cr
2025-02-09  1:47             ` Florian Westphal
2025-02-09  3:12               ` Sunny73Cr
2025-02-09 22:23                 ` Pablo Neira Ayuso
2025-02-09 22:45                   ` Sunny73Cr
2025-12-02  5:22                     ` Sunny73Cr

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=20250128003706.GB29891@breakpoint.cc \
    --to=fw@strlen.de \
    --cc=Sunny73Cr@protonmail.com \
    --cc=netfilter@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 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.