Netdev Archive on lore.kernel.org
help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: johannes@sipsolutions.net
Cc: netdev@vger.kernel.org, kuba@kernel.org,
linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com,
johannes.berg@intel.com,
syzbot+353df1490da781637624@syzkaller.appspotmail.com
Subject: Re: [PATCH] netlink: policy: correct validation type check
Date: Mon, 31 Aug 2020 12:02:50 -0700 (PDT) [thread overview]
Message-ID: <20200831.120250.1316279201672077612.davem@davemloft.net> (raw)
In-Reply-To: <20200831202805.8ca5a2fe1ffb.I46f0d5bee0a774517aeec539620895a473dd2299@changeid>
From: Johannes Berg <johannes@sipsolutions.net>
Date: Mon, 31 Aug 2020 20:28:05 +0200
> From: Johannes Berg <johannes.berg@intel.com>
>
> In the policy export for binary attributes I erroneously used
> a != NLA_VALIDATE_NONE comparison instead of checking for the
> two possible values, which meant that if a validation function
> pointer ended up aliasing the min/max as negatives, we'd hit
> a warning in nla_get_range_unsigned().
>
> Fix this to correctly check for only the two types that should
> be handled here, i.e. range with or without warn-too-long.
>
> Reported-by: syzbot+353df1490da781637624@syzkaller.appspotmail.com
> Fixes: 8aa26c575fb3 ("netlink: make NLA_BINARY validation more flexible")
> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Applied, thank you.
prev parent reply other threads:[~2020-08-31 19:02 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-31 16:47 WARNING in nla_get_range_unsigned syzbot
2020-08-31 18:28 ` [PATCH] netlink: policy: correct validation type check Johannes Berg
2020-08-31 19:02 ` David Miller [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=20200831.120250.1316279201672077612.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=johannes.berg@intel.com \
--cc=johannes@sipsolutions.net \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=syzbot+353df1490da781637624@syzkaller.appspotmail.com \
--cc=syzkaller-bugs@googlegroups.com \
--subject='Re: [PATCH] netlink: policy: correct validation type check' \
/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
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).