From: Jakub Kicinski <kuba@kernel.org>
To: Manas via B4 Relay <devnull+manas18244.iiitd.ac.in@kernel.org>
Cc: manas18244@iiitd.ac.in, "David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
Kuniyuki Iwashima <kuniyu@amazon.com>,
Shuah Khan <shuah@kernel.org>,
Anup Sharma <anupnewsmail@gmail.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
syzbot+d4373fa8042c06cefa84@syzkaller.appspotmail.com
Subject: Re: [PATCH net v2] netlink: Add string check in netlink_ack_tlv_fill
Date: Wed, 13 Nov 2024 18:25:11 -0800 [thread overview]
Message-ID: <20241113182511.41960cc0@kernel.org> (raw)
In-Reply-To: <20241114-fix-netlink_ack_tlv_fill-v2-1-affdfb5f4c6f@iiitd.ac.in>
On Thu, 14 Nov 2024 06:15:15 +0530 Manas via B4 Relay wrote:
> - if (extack->bad_attr &&
> + if (extack->bad_attr && strlen(in_skb->data) &&
> !WARN_ON((u8 *)extack->bad_attr < in_skb->data ||
> (u8 *)extack->bad_attr >= in_skb->data + in_skb->len))
that's most definitely not the right fix.
in_skb->data points to binary data.
my best idea so far is to rework this check to use nlh, because in_skb
will be pulled at this stage for dumps
if that makes sense to you please give it a go, otherwise I'll work on
the fix tomorrow
next prev parent reply other threads:[~2024-11-14 2:25 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-14 0:45 [PATCH net v2] netlink: Add string check in netlink_ack_tlv_fill Manas
2024-11-14 0:45 ` Manas via B4 Relay
2024-11-14 2:25 ` Jakub Kicinski [this message]
2024-11-14 8:07 ` Manas
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=20241113182511.41960cc0@kernel.org \
--to=kuba@kernel.org \
--cc=anupnewsmail@gmail.com \
--cc=davem@davemloft.net \
--cc=devnull+manas18244.iiitd.ac.in@kernel.org \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuniyu@amazon.com \
--cc=linux-kernel@vger.kernel.org \
--cc=manas18244@iiitd.ac.in \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=shuah@kernel.org \
--cc=syzbot+d4373fa8042c06cefa84@syzkaller.appspotmail.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.